[QVTO] Run transformation via extension point "org.eclipse.m2m.qvt.oml.runtime.qvtTransformatio [message #836714] |
Wed, 04 April 2012 16:39  |
Eclipse User |
|
|
|
My transformation project extends "org.eclipse.m2m.qvt.oml.runtime.qvtTransformation". Hence, if located in the development workspace, the transformation is executable in the runtime workspace.
This works up to the point where I make one of the input/output ecore meta-models reference another ecore (i.e. an EClass in my input or output ecore has an EReference to an EClass within another ecore, which is neither input nor output). If I refer to that EReference leading to the other ecore, I get the error message "Failed to parse transformation" when trying to execute the transformation in the runtime workspace. This is strange, because in the development workspace, there are no compilation errors.
Does anyone have an idea? Do I need to register the referenced ecore as part of the extension?
|
|
|
Re: [QVTO] Run transformation via extension point "org.eclipse.m2m.qvt.oml.runtime.qvtTrans [message #837134 is a reply to message #836714] |
Thu, 05 April 2012 05:57   |
Eclipse User |
|
|
|
Hi
"Do I need to register the referenced ecore as part of the extension? "
Sort of.
When you run within Eclipse inter-model references are comparatively
easy since you have a normalising environment that ensures that
- packages such as http://www.eclipse.org/emf/2002/Ecore are registered
automatically
- pseudo-locations such as platform:/plugin and platform:/resource
exists and are mutually ../../.. navigable
None of this happens once you leave Eclipse and run standalone
Registering packages is easy, and actually happens just by referring to
them: EPackage.eINSTANCE.getClass()
Making platform: and ../.. navigation work is hard;
https://bugs.eclipse.org/bugs/show_bug.cgi?id=361063 is a solution.
I recommend only using http: and at most intra-project ../.. navigation
to keep things simple. You can use file: to make it work for you today,
but don't expect it to work for anyone else, or even you once code has
bounced in and out of a CM tool.
Remember that your stabdalone configuration must match your Eclipse
configuration if facilities used within Eclipse are to be similarly
referenceable standalone.
Regards
Ed Willink
On 04/04/2012 21:39, Missing name Mising name wrote:
> My transformation project extends
> "org.eclipse.m2m.qvt.oml.runtime.qvtTransformation". Hence, if located
> in the development workspace, the transformation is executable in the
> runtime workspace.
>
> This works up to the point where I make one of the input/output ecore
> meta-models reference another ecore (i.e. an EClass in my input or
> output ecore has an EReference to an EClass within another ecore,
> which is neither input nor output). If I refer to that EReference
> leading to the other ecore, I get the error message "Failed to parse
> transformation" when trying to execute the transformation in the
> runtime workspace. This is strange, because in the development
> workspace, there are no compilation errors.
>
> Does anyone have an idea? Do I need to register the referenced ecore
> as part of the extension?
|
|
|
|
Re: [QVTO] Run transformation via extension point "org.eclipse.m2m.qvt.oml.runtime.qvtT [message #838643 is a reply to message #838632] |
Sat, 07 April 2012 07:27  |
Eclipse User |
|
|
|
Hi
Yes. Sometimes EMF's omission of empty packages is too helpful. Try
putting in a dummy class.
Regards
Ed Willink
On 07/04/2012 12:04, Missing name Mising name wrote:
> Thanks for your support.
>
> I think the problem occurs again due to the fact that I have nested
> packages within the referenced ecore file.
>
> Within my transformation, I only import the toplevel package of my
> ecore. This one is empty (no classes, just sub-packages), so no
> EPackage is generated. Hence, the imported nsURI can't be resolved in
> the runtime workspace.
|
|
|
Powered by
FUDForum. Page generated in 0.23739 seconds