Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » ATL » HOW CAI I DO (The problem of transition)
HOW CAI I DO [message #1021523] Wed, 20 March 2013 09:15 Go to next message
yesheng chai is currently offline yesheng chaiFriend
Messages: 64
Registered: March 2013
Member
rule Activity
{      from   s:Activities!Activity
	to   t1:PetriNets!PetriNet
		(name <- s.name)
}
rule Action
{from       s:Activities!Action
     to       t1:PetriNets!Place
	     	( name <- s.name,id <- s.id)
}

my input xmi:
<Activity  name="sleep">
     <Action name="eat" id="33"/>
     </Activity>

The error is:
FeatureNotFoundException: Feature 'Action' not found.
Thank you very much !
Re: HOW CAI I DO [message #1021687 is a reply to message #1021523] Wed, 20 March 2013 14:11 Go to previous messageGo to next message
yesheng chai is currently offline yesheng chaiFriend
Messages: 64
Registered: March 2013
Member
it looks to me that your XMI file is not correct. It should be something like this:
<Activity name="First">
<name-of-the-feature name="one" id="1"/>
</Activity>
</xmi:XMI>
Re: HOW CAI I DO [message #1021757 is a reply to message #1021687] Wed, 20 March 2013 16:20 Go to previous messageGo to next message
Hugo Bruneliere is currently offline Hugo BruneliereFriend
Messages: 674
Registered: July 2009
Senior Member
Hello,

First, independently from the transformation, how have you built your input model?
Are you able to open/load it correctly using the Sample Reflective Model Editor for instance?

Hugo


--------------------------------------------------------
Hugo Bruneliere, PhD
NaoMod team (IMT Atlantique & LS2N-CNRS)
Nantes - France
--------------------------------------------------------
Re: HOW CAI I DO [message #1021954 is a reply to message #1021757] Thu, 21 March 2013 01:29 Go to previous messageGo to next message
yesheng chai is currently offline yesheng chaiFriend
Messages: 64
Registered: March 2013
Member
Thank you for your reply .
MY input model is wrong . Action is not the feature of the Activity and it just a class belonging to Activity class which contains Action.I replace Aciton with actions which is a reference so that the project run successfully .
Re: HOW CAI I DO [message #1024869 is a reply to message #1021757] Tue, 26 March 2013 09:31 Go to previous messageGo to next message
Walid Rabie is currently offline Walid RabieFriend
Messages: 3
Registered: March 2013
Junior Member
Hello,
Am new on atl Transformations and i had the same problem as Mr yesheng chai,so i would thank you for your help and i appreciate the great work that are doing the forum's team!
However i would ask Mr Hugo Bruneliere for his reply,
>>First, independently from the transformation, how have you built your input >>model?Are you able to open/load it correctly using the Sample Reflective Model >>Editor for instance?

Its interesting for me to know exactly how to define and use XMI Models, my XMI model can't be open with "Sample Reflective Model 'Ecore' Model Editor "[note that i have "Ecore Model Editor" not "Model Editor],and when trying opening it i got this message "Problems encountered. Click the 'Details' button for further information".

And am wondering if ,each time i wont to declare a subclass into the containing Class in the XMI Model, i have to put the EReference Of the SubClass not the SubClass it Self.

The last question: is there other option to use models with another langage other than XMI.


Thanks in advance for the help!
Re: HOW CAI I DO [message #1027126 is a reply to message #1024869] Tue, 26 March 2013 15:31 Go to previous messageGo to next message
Hugo Bruneliere is currently offline Hugo BruneliereFriend
Messages: 674
Registered: July 2009
Senior Member
Hello,

When opening your model with an editor, you first have to be sure that the corresponding metamodel (in Ecore) is correctly loaded onto the EMF registry.
For integrated metamodels, this is normally already done when starting your Eclipse.
For development ones in your workspace, you can load them manually thanks to the "Load Metamodel" action (on an Ecore file) as provided by ATL from the ATL perspective.

Concerning the storage/serialization of models, yes there is potentially an infinite number of options (as long as you provide the right corresponding model loader/saver). For instance, they can be stored in databases (cf. Eclipse CDO), in XML files (cf. base Eclipse EMF), in textual files (cf. Eclipse Xtext), etc.

Best regards,

Hugo


--------------------------------------------------------
Hugo Bruneliere, PhD
NaoMod team (IMT Atlantique & LS2N-CNRS)
Nantes - France
--------------------------------------------------------
Re: HOW CAI I DO [message #1027819 is a reply to message #1027126] Wed, 27 March 2013 12:58 Go to previous messageGo to next message
Walid Rabie is currently offline Walid RabieFriend
Messages: 3
Registered: March 2013
Junior Member
Hello,

Thank you for your reply, Mr Hugo Bruneliere, i tried to do what you advised me about loading the metamodel, in my case i developed my own metamodel (.ecore)in my workspace, but i didn't find where to load it as you said! note that my transformation works and i got the target metamodel, and i dont know if am on the right way or not! i would also ask you about the role of Ns prefix and Ns URI when creating an new metamodel!

Thanks For the Help!
Re: HOW CAI I DO [message #1027911 is a reply to message #1027819] Wed, 27 March 2013 15:35 Go to previous messageGo to next message
Hugo Bruneliere is currently offline Hugo BruneliereFriend
Messages: 674
Registered: July 2009
Senior Member
Hello,

If you open the ATL perspective and go to the corresponding navigator, the "Load Metamodel" contextual action should be available on Ecore files.

Concerning your latest question, the URI is the string used by EMF to identify your metamodel when loaded onto the EMF registry.
The prefix is primarily used in the context of the XMI serialization of the corresponding models.

Best regards,

Hugo


--------------------------------------------------------
Hugo Bruneliere, PhD
NaoMod team (IMT Atlantique & LS2N-CNRS)
Nantes - France
--------------------------------------------------------
Re: HOW CAI I DO [message #1035948 is a reply to message #1027911] Sun, 07 April 2013 18:17 Go to previous message
Walid Rabie is currently offline Walid RabieFriend
Messages: 3
Registered: March 2013
Junior Member
Thanks for the help!
Previous Topic:Using UML profile as metamodel
Next Topic:From UML Class diagram to Relational DB
Goto Forum:
  


Current Time: Fri Mar 29 06:17:55 GMT 2024

Powered by FUDForum. Page generated in 0.02397 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top