use of de.be4.classicalb.core.parser.node.ARefinesModelClause in project prob2 by bendisposto.
the class EventBMachineTranslator method translateMachine.
public Node translateMachine() {
AEventBModelParseUnit ast = new AEventBModelParseUnit();
ast.setName(new TIdentifierLiteral(machine.getName()));
List<PModelClause> clauses = new ArrayList<>();
clauses.add(processContexts());
ARefinesModelClause refines = processRefines();
if (refines != null) {
clauses.add(refines);
}
clauses.add(processVariables());
clauses.addAll(processInvariantsAndTheorems());
AVariantModelClause variant = processVariant();
if (variant != null) {
clauses.add(variant);
}
clauses.add(processEvents());
ast.setModelClauses(clauses);
return ast;
}
Aggregations