I have setup a little project for generating code from the ecore class "EClass".
I try to generate the following:
public class EClassWalkable implements IWalkable<EClass, EClassWalker> {
}
But I get this:
public class EClassWalkable implements org.xtext.example.mydsl10.jvmmodel.IWalkable {
}
For simplicity I ommited the methods.
As I figured out by debugging is that the type reference resolution process could not find a resourceSet for EClass. That led the process to not correctly generate the type parameter of the IWalkable interface.
I used "EcorePackage.eINSTANCE.EClass" to get the EClass object.
Now my questions:
Is this a bug or a feature ?
Is there another way to get the EClass object beeing attached to it's resourceSet ?
The zip consists of three projects:
org.eclispe.example.mydsl10 - the DSL Project currently only used for triggering the xbase code generation
org.eclispe.example.mydsl10.ui - the DSL Project currently only used for triggering the xbase code generation
org.eclispe.example.mydsl10.test - the DSL Instance Project currently only used for triggering the xbase code
generation
org.eclispe.example.mydsl10.test imports org.eclispe.example.mydsl10 and org.eclipse.emf.ecore
I removed the binary files since they will be generated by running the workflow or the generator
The both classes of interesst are
org.xtext.example.mydsl10.jvmmodel.MyDslJvmModelInferrer - generated by Xtext
org.xtext.example.mydsl10.jvmmodel.EcoreWalkableInferrer - hand made