Transition transition = (Transition) transitions.next();
// generate code for guard expression
String guard = transition.getGuardExpression();
PtParser parser = new PtParser();
ASTPtRootNode guardParseTree = parser.generateParseTree(guard);
ParseTreeCodeGenerator parseTreeCodeGenerator = controllerHelper
.getParseTreeCodeGenerator();
parseTreeCodeGenerator.evaluateParseTree(guardParseTree,
controllerHelper._scope);
codeBuffer.append(parseTreeCodeGenerator.generateFireCode());
codeBuffer.append(") {" + _eol);
// generate code for commit action
Iterator actions = transition.commitActionList().iterator();
while (actions.hasNext()) {
AbstractActionsAttribute action = (AbstractActionsAttribute) actions
.next();
Iterator destinationNameList = action.getDestinationNameList()
.iterator();
while (destinationNameList.hasNext()) {
String destinationName = (String) destinationNameList
.next();
NamedObj destination = action
.getDestination(destinationName);
ASTPtRootNode parseTree = action
.getParseTree(destinationName);
if (destination instanceof Variable) {
codeBuffer.append(_codeGenerator
.generateVariableName((Variable) destination)
+ " = ");