de.uni_hildesheim.sse.vil.rt.GenerateRtVil.mwe2 Maven / Gradle / Ivy
module de.uni_hildesheim.sse.vil.rt.GenerateRtVil
import org.eclipse.emf.mwe.utils.*
import org.eclipse.xtext.generator.*
import org.eclipse.xtext.ui.generator.*
var grammarURI = "classpath:/de/uni_hildesheim/sse/vil/rt/RtVil.xtext"
var file.extensions = "rtvil"
var projectName = "de.uni_hildesheim.sse.vil.rt"
var runtimeProject = "../${projectName}"
Workflow {
bean = StandaloneSetup {
scanClassPath = true
platformUri = "${runtimeProject}/.."
// The following two lines can be removed, if Xbase is not used.
//registerGeneratedEPackage = "org.eclipse.xtext.xbase.XbasePackage"
//registerGenModelFile = "platform:/resource/org.eclipse.xtext.xbase/model/Xbase.genmodel"
//registerGeneratedEPackage = "de.uni_hildesheim.sse.vil.expressions.expressionDsl.ExpressionDslPackage"
//registerGenModelFile = "platform:/resource/de.uni_hildesheim.sse.vil.expressions/src-gen/de/uni_hildesheim/sse/vil/expressions/ExpressionDsl.genmodel"
registerGeneratedEPackage = "de.uni_hildesheim.sse.vilBuildLanguage.VilBuildLanguagePackage"
registerGenModelFile = "platform:/resource/de.uni_hildesheim.sse.vil.buildlang/src-gen/de/uni_hildesheim/sse/VilBuildLanguage.genmodel"
}
component = DirectoryCleaner {
directory = "${runtimeProject}/src-gen"
}
component = DirectoryCleaner {
directory = "${runtimeProject}/model"
}
component = DirectoryCleaner {
directory = "${runtimeProject}.ui/src-gen"
}
component = DirectoryCleaner {
directory = "${runtimeProject}.tests/src-gen"
}
component = Generator {
pathRtProject = runtimeProject
pathUiProject = "${runtimeProject}.ui"
pathTestProject = "${runtimeProject}.tests"
projectNameRt = projectName
projectNameUi = "${projectName}.ui"
language = {
uri = grammarURI
fileExtensions = file.extensions
// Java API to access grammar elements (required by several other fragments)
fragment = grammarAccess.GrammarAccessFragment {}
// generates Java API for the generated EPackages
fragment = ecore.EMFGeneratorFragment {}
// the old serialization component
fragment = parseTreeConstructor.ParseTreeConstructorFragment {}
// serializer 2.0
//fragment = serializer.SerializerFragment auto-inject {
// generateStub = false
//}
// a custom ResourceFactory for use with EMF
fragment = resourceFactory.ResourceFactoryFragment {
fileExtensions = file.extensions
}
// The antlr parser generator fragment.
fragment = parser.antlr.XtextAntlrGeneratorFragment {
options = {
backtrack = true
}
}
// Xtend-based API for validation
fragment = validation.JavaValidatorFragment {
composedCheck = "org.eclipse.xtext.validation.ImportUriValidator"
// CK: excluded to enable the definition of multiple equal identifier
//composedCheck = "org.eclipse.xtext.validation.NamesAreUniqueValidator"
}
// old scoping and exporting API
// fragment = scoping.ImportURIScopingFragment auto-inject {}
// fragment = exporting.SimpleNamesFragment auto-inject {}
// scoping and exporting API
fragment = scoping.ImportNamespacesScopingFragment {}
fragment = exporting.QualifiedNamesFragment {}
fragment = builder.BuilderIntegrationFragment {}
// generator API
fragment = generator.GeneratorFragment {
generateMwe = true
generateJavaMain = true
}
// formatter API
fragment = formatting.FormatterFragment {}
// labeling API
fragment = labeling.LabelProviderFragment {}
// outline API
fragment = outline.OutlineTreeProviderFragment {}
fragment = outline.QuickOutlineFragment {}
// quickfix API
fragment = quickfix.QuickfixProviderFragment {}
// content assist API
fragment = contentAssist.JavaBasedContentAssistFragment {}
// generates a more lightweight Antlr parser and lexer tailored for content assist
fragment = parser.antlr.XtextAntlrUiGeneratorFragment {}
// generates junit test support classes into Generator#pathTestProject
//fragment = junit.Junit4Fragment auto-inject {}
// rename refactoring
//fragment = refactoring.RefactorElementNameFragment auto-inject {}
// provides the necessary bindings for java types integration
fragment = types.TypesGeneratorFragment {}
// generates the required bindings only if the grammar inherits from Xbase
fragment = xbase.XbaseGeneratorFragment {}
// provides a preference page for template proposals
fragment = templates.CodetemplatesGeneratorFragment auto-inject {}
// provides a compare view
// fragment = compare.CompareFragment {
// fileExtensions = file.extensions
// }
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy