use of org.eclipse.titan.designer.AST.TTCN3.statements.Activate_Statement in project titan.EclipsePlug-ins by eclipse.
the class FMDefaultActivations method measure.
@Override
public Number measure(final MetricData data, final Def_Function function) {
final Counter count = new Counter(0);
function.accept(new CounterVisitor(count) {
@Override
public int visit(final IVisitableNode node) {
if (node instanceof Activate_Statement) {
count.inc();
} else if (node instanceof Activate_Referenced_Statement) {
count.inc();
} else if (node instanceof ActivateDereferedExpression) {
count.inc();
} else if (node instanceof ActivateExpression) {
count.inc();
}
return V_CONTINUE;
}
});
return count.val();
}
Aggregations