[MOFScript] Java Api howto [message #376303] |
Mon, 05 March 2007 10:33  |
Eclipse User |
|
|
|
Originally posted by: angel.calvo.centic.es
Hello,
I'm using the MOFScript Java API like in the example of the User Manual,
and my question is: How I can set a transformation for the execution
manager without parse it?
Thanks,
|
|
|
Re: [MOFScript] Java Api howto [message #376304 is a reply to message #376303] |
Fri, 09 March 2007 03:02  |
Eclipse User |
|
|
|
Hi Angel Luis,
You can only do this if you have a model representation (EMF) of your
transformation instead the textual representation.
If you have the model representation, you can do the following:
ExecutionManager execMgr = ExecutionManager.getExecutionManager();
MOfScriptSpecification mofsciptSpec = <load your transformation model from
somewhere>
execMgr.setTransformationModel (mofscriptSpec);
execMgr.executeTransformation ();
If you do not have your transformation represented as a model, you cannot
bypass parsing. You need to run the parser to obtain a valid representation
(model) of your transformation. After you have done this one time - and you
are not going to modify your transformation, you can store your
transformation model and exeecute that as illustrated above.
Best regards,
Jon Oldevik
"Angel Luis Calvo Ortega" <angel.calvo@centic.es> wrote in message
news:eshd6f$h2c$1@utils.eclipse.org...
> Hello,
>
> I'm using the MOFScript Java API like in the example of the User Manual,
> and my question is: How I can set a transformation for the execution
> manager without parse it?
>
> Thanks,
|
|
|
Re: [MOFScript] Java Api howto [message #578006 is a reply to message #376303] |
Fri, 09 March 2007 03:02  |
Eclipse User |
|
|
|
Hi Angel Luis,
You can only do this if you have a model representation (EMF) of your
transformation instead the textual representation.
If you have the model representation, you can do the following:
ExecutionManager execMgr = ExecutionManager.getExecutionManager();
MOfScriptSpecification mofsciptSpec = <load your transformation model from
somewhere>
execMgr.setTransformationModel (mofscriptSpec);
execMgr.executeTransformation ();
If you do not have your transformation represented as a model, you cannot
bypass parsing. You need to run the parser to obtain a valid representation
(model) of your transformation. After you have done this one time - and you
are not going to modify your transformation, you can store your
transformation model and exeecute that as illustrated above.
Best regards,
Jon Oldevik
"Angel Luis Calvo Ortega" <angel.calvo@centic.es> wrote in message
news:eshd6f$h2c$1@utils.eclipse.org...
> Hello,
>
> I'm using the MOFScript Java API like in the example of the User Manual,
> and my question is: How I can set a transformation for the execution
> manager without parse it?
>
> Thanks,
|
|
|
Powered by
FUDForum. Page generated in 0.31298 seconds