|
Re: Issues Generating with JavaImporterApplication [message #691876 is a reply to message #691841] |
Sat, 02 July 2011 17:13 |
Ed Merks Messages: 33145 Registered: July 2009 |
Senior Member |
|
|
Alain,
Comments below.
On 02/07/2011 7:32 AM, Alain Picard wrote:
> I'm trying to use the JavaImporterApplication to generate a genmodel
> and ecore from some annotated Java programmatically.
>
> The process works quite well but with a few issues:
> 1- I can't seem to be able to set my ecore file name
> I have a package called demo and I want to get my ecore to be
> MyDemo.ecore
Gosh, it's been a while since I did this...
>
> 2- My package nsURI seems to be changed:
> I am submitting a package with an nsURI of:
> http://demo.ist.emf.iris.castortech.com/spec/1.0
> and I get:
> http:///com/castortech/iris/emf/language/demo.ecore
The nsURI is specified in the @model information?
>
> 3- My template directory is being screwed up:
> I submit: "/com.castortech.jtb/templates/emfgen"
> and I get: "file:/C:/com.castortech.jtb/templates/emfgen", which is
> invalid by the way, as the right version is rooted at the workspace
> not the drive, which is also non-portable.
You're running this application with a workspace?
>
> 4- How can I set other genmodel features for which there are not
> arguments, like rootExtendsInterface, rootExtendsClass,
> modelPluginVariables?
You don't...
It would be better if you created your *.genmodel in the IDE and then
used the importer application to reload it. That way you can specify
everything you want and have it stay that way. It's would be a huge
task to make everything that can be configured in the GenModel be
controllable via a command line equivalent.
> Thanks
> Alain
>
>
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Re: Issues Generating with JavaImporterApplication [message #692205 is a reply to message #691876] |
Sun, 03 July 2011 22:07 |
Alain Picard Messages: 266 Registered: July 2009 |
Senior Member |
|
|
See below
On 7/2/2011 1:13 PM, Ed Merks wrote:
> Alain,
>
> Comments below.
>
>
> On 02/07/2011 7:32 AM, Alain Picard wrote:
>> I'm trying to use the JavaImporterApplication to generate a genmodel
>> and ecore from some annotated Java programmatically.
>>
>> The process works quite well but with a few issues:
>> 1- I can't seem to be able to set my ecore file name
>> I have a package called demo and I want to get my ecore to be
>> MyDemo.ecore
> Gosh, it's been a while since I did this...
There's a time for trying everything. So is there a way to specify the
..ecore name, that is one of my biggest remaining issue.
>>
>> 2- My package nsURI seems to be changed:
>> I am submitting a package with an nsURI of:
>> http://demo.ist.emf.iris.castortech.com/spec/1.0
>> and I get:
>> http:///com/castortech/iris/emf/language/demo.ecore
> The nsURI is specified in the @model information?
Do you mean that I need to provide a certain annotation and if so where,
in a package interface?
>>
>> 3- My template directory is being screwed up:
>> I submit: "/com.castortech.jtb/templates/emfgen"
>> and I get: "file:/C:/com.castortech.jtb/templates/emfgen", which is
>> invalid by the way, as the right version is rooted at the workspace
>> not the drive, which is also non-portable.
> You're running this application with a workspace?
Yes, I am. I've changed it by extending JavaImporterApplication and
providing for the setting of the options in 4 and also for the template
directory, which fixed the problem. But I believe the code in the
generator is wrong in not directly taking the string supplied and trying
to do some sort of URI manipulation on it.
>>
>> 4- How can I set other genmodel features for which there are not
>> arguments, like rootExtendsInterface, rootExtendsClass,
>> modelPluginVariables?
> You don't...
Well I do now, see above.
>
> It would be better if you created your *.genmodel in the IDE and then
> used the importer application to reload it. That way you can specify
> everything you want and have it stay that way. It's would be a huge task
> to make everything that can be configured in the GenModel be
> controllable via a command line equivalent.
I absolutely need to automate the full generation process, as I'm also
intertwining other steps in the process.
>> Thanks
>> Alain
>>
>>
|
|
|
Powered by
FUDForum. Page generated in 0.02432 seconds