[ATL] Error loading platform [message #524000] |
Tue, 30 March 2010 09:05 |
MaximeLecourt Messages: 108 Registered: February 2010 Location: France |
Senior Member |
|
|
I created a Xpand project, with two metamodels, one called metamodel (an object metamodel), and another metamodel called relationnel (an relationnal metamodel).
Now I'm trying to transform an xmi model I created following the object metamodel into a relationnal metamodel.
I started with the basics, for all objects of type Class (in object metamodel), I want an Object of type Table (in relationnal metamodel). both have a name attribute.
when I try to run my ATL file, I get
Error loading platform:/resource/Object2Relationnal/metamodels/metamodel.ecore: null
What does that mean ?
my metamodel is in metamodels folder, and the project name is Object2Relationnal, so it should be able to find it.
Here is my atl file
module Object2Relationnal;
-- @path Object=/metamodels/metamodel.ecore
-- @path Relationnel=/metamodels/relationnel.ecore
create Out : Relationnel from IN : Object;
-- Takes all classes from Model, and creates a Table from it
rule Class2Table{
from
s : Object!Class
to
t : Relationnel!Table(
name <- s.name
)
}
One day I shall master M2T, but that day has yet to come...
|
|
|
Re: [ATL] Error loading platform [message #524030 is a reply to message #524000] |
Tue, 30 March 2010 07:18 |
Eclipse User |
|
|
|
Originally posted by: thierry.fortin.obeo.fr
Hello Maxime,
First of all, your two "-- @path" lines won't work, because you have to
include the project name in the path. So your complete path lines would be:
-- @path Object=/Object2Relationnal/metamodels/metamodel.ecore
-- @path Relationnel=/Object2Relationnal/metamodels/relationnel.ecore
These lines are generally put at the top of the file, above the module
declaration. But actually, they are only used for completion, so it
won't solve your problem.
Concerning the error you get, it's weird. Are you sure about your launch
configuration, that everything is correct (no confusion between
"relationnal" and "relationnel")? Could you be more accurate about you
launching the transformation?
Regards,
Thierry
Le 30/03/2010 11:05, Maxime Lecourt a écrit :
> I created a Xpand project, with two metamodels, one called metamodel (an
> object metamodel), and another metamodel called relationnel (an
> relationnal metamodel).
>
> Now I'm trying to transform an xmi model I created following the object
> metamodel into a relationnal metamodel.
>
> I started with the basics, for all objects of type Class (in object
> metamodel), I want an Object of type Table (in relationnal metamodel).
> both have a name attribute.
>
> when I try to run my ATL file, I get
> Error loading
> platform:/resource/Object2Relationnal/metamodels/metamodel.e core: null
>
>
> What does that mean ?
> my metamodel is in metamodels folder, and the project name is
> Object2Relationnal, so it should be able to find it.
>
> Here is my atl file
> module Object2Relationnal;
>
> -- @path Object=/metamodels/metamodel.ecore
> -- @path Relationnel=/metamodels/relationnel.ecore
>
> create Out : Relationnel from IN : Object;
>
> -- Takes all classes from Model, and creates a Table from it
> rule Class2Table{
> from
> s : Object!Class
> to
> t : Relationnel!Table(
> name <- s.name
> )
> }
|
|
|
|
|
|
|
|
|
Re: [ATL] Error loading platform [message #670813 is a reply to message #535282] |
Sun, 15 May 2011 17:31 |
Tom2000 Messages: 6 Registered: May 2011 |
Junior Member |
|
|
Here an other solution for the still existing problem.
In Persons.ecore file add
Name = Families
NS URI = http:someArbitraryNamespaceURI/Families/
Note: leave out NSPrefix
In Persons.ecore file add
Name = Persons
NS URI = http:someArbitraryNamespaceURI/Persons/
Note: leave out NSPrefix
and then add the namespace in sample-Families.ecore
<xmi:XMI xmi:version="2.0" xmlns:xmi="..."
xmlns="http:someArbitraryNamespaceURI/Families/">
<Family lastName="March">
<father firstName="Jim"/>
<mother firstName="Cindy"/>
<sons firstName="Brandon"/>
<daughters firstName="Brenda"/>
</Family> ...
greetings
Tom
(Sorry but i cant use links until 5 messages)
[Updated on: Sun, 15 May 2011 17:31] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.04949 seconds