Skip to content

Commit

Permalink
Fixes #303
Browse files Browse the repository at this point in the history
  • Loading branch information
aedelmann committed Jun 26, 2016
1 parent 3d2010c commit 86fb5ce
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,17 @@ class GeneratorTemplate implements IFileTemplate<IGeneratorProjectContext> {
import org.eclipse.vorto.codegen.api.GenerationResultZip
import org.eclipse.vorto.codegen.api.GeneratorTaskFromFileTemplate
import org.eclipse.vorto.codegen.api.IFileTemplate
import org.eclipse.vorto.codegen.api.IMappingContext
import org.eclipse.vorto.codegen.api.mapping.InvocationContext;
import org.eclipse.vorto.codegen.api.IVortoCodeGenerator
import org.eclipse.vorto.core.api.model.informationmodel.InformationModel
class «context.generatorName» implements IVortoCodeGenerator {
override generate(InformationModel infomodel, IMappingContext mappingContext) {
override generate(InformationModel infomodel, InvocationContext context) {
var output = new GenerationResultZip(infomodel,getServiceKey());
var generator = new ChainedCodeGeneratorTask<InformationModel>();
generator.addTask(new GeneratorTaskFromFileTemplate(new SampleTemplate()));
generator.generate(infomodel,mappingContext,output);
generator.generate(infomodel,context,output);
return output
}
Expand All @@ -61,7 +61,7 @@ class GeneratorTemplate implements IFileTemplate<IGeneratorProjectContext> {
return "output"
}
override getContent(InformationModel context) {
override getContent(InformationModel model, InvocationContext context) {
return '//Generated by «context.generatorName»';
}
}
Expand Down

0 comments on commit 86fb5ce

Please sign in to comment.