diff --git a/AlgebraicDataflowArchitectureModel/src/algorithms/CodeGenerator.java b/AlgebraicDataflowArchitectureModel/src/algorithms/CodeGenerator.java index 912d44a..090c121 100644 --- a/AlgebraicDataflowArchitectureModel/src/algorithms/CodeGenerator.java +++ b/AlgebraicDataflowArchitectureModel/src/algorithms/CodeGenerator.java @@ -80,7 +80,7 @@ ((ResourceNode) re.getDestination()).getIdentifierTemplate().getResourceName())); cons.addParameter(new VariableDeclaration(new Type(rename, rename), ((ResourceNode) re.getDestination()).getIdentifierTemplate().getResourceName())); - block.addStatement("this." + rename.toLowerCase() + " = " + rename.toLowerCase()); + block.addStatement("this." + rename.toLowerCase() + " = " + rename.toLowerCase() + ";"); cons.setBody(block); } } @@ -97,7 +97,7 @@ ((ResourceNode) re.getSource()).getIdentifierTemplate().getResourceName())); cons.addParameter(new VariableDeclaration(new Type(rename, rename), ((ResourceNode) re.getSource()).getIdentifierTemplate().getResourceName())); - block.addStatement("this." + rename.toLowerCase() + " = " + rename.toLowerCase()); + block.addStatement("this." + rename.toLowerCase() + " = " + rename.toLowerCase() + ";"); cons.setBody(block); } else { vars.add(new VariableDeclaration( @@ -117,6 +117,7 @@ ((Term) cm.getStateTransition().getMessageExpression()).getSymbol().getImplName(),false, typeVoid,params); type.addMethod(io); + codes.get(0).addMethod(io); } } } @@ -135,7 +136,6 @@ rn.getIdentifierTemplate().getResourceStateType())); codes.add(type); } - codes.get(0).addMethod(new MethodDeclaration("input", typeVoid)); for (Node n : graph.getNodes()) { ResourceNode rn = (ResourceNode) n; MethodDeclaration get = new MethodDeclaration(