Create a command that generate code [message #34436] |
Sat, 29 September 2007 13:00 |
Eclipse User |
|
|
|
Originally posted by: ijerez2001.msn.com
I need help with a GMF editor.
I need create code from a GMF model, so, I want to create a command in the
menu for GMF editor that call to a command to generate code.
I try to use JET, but I don´t know link my model with the command.
Thanks.
|
|
|
|
Re: Create a command that generate code [message #34570 is a reply to message #34538] |
Mon, 01 October 2007 15:29 |
Eclipse User |
|
|
|
Originally posted by: ijerez2001.gmail.com
Thanks Paul.
"Paul Elder" <pelder@ca.ibm.com> escribió en el mensaje de
noticias:fdqosn$m9f$1@build.eclipse.org...
> Ivan:
>
> I will assume that you know how to create a command in a GMF editor. If
> not, please ask the GMF newsgroup.
>
> As for invoking JET from that command, do the following.
>
> 1) get the EMF Resource object for your model. From any model element, you
> can get this by calling modelElement.eResource().
>
> 2) Call JET as follows:
>
> JET2Platform.runTransformOnObject( "your jet transformations plug-in
> id", theEMFResource, aProgressMonitor);
>
> The method returns an IStatus that contains any execution error messages.
>
> Paul
>
> "Iván Jerez" <ijerez2001@msn.com> wrote in message
> news:fdli99$o3v$1@build.eclipse.org...
>>I need help with a GMF editor.
>>
>> I need create code from a GMF model, so, I want to create a command in
>> the menu for GMF editor that call to a command to generate code.
>> I try to use JET, but I don´t know link my model with the command.
>>
>> Thanks.
>>
>>
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.02981 seconds