Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » MOFScript » MOFScript and UML State machines
MOFScript and UML State machines [message #580123] Mon, 02 November 2009 16:52 Go to next message
ASN  is currently offline ASN
Messages: 6
Registered: November 2009
Junior Member
Hello,

I am using MOFScript to parse an UML model of a State Machine. I have been able to do it without major complications but for some reason I cannot access the "Trigger"s in the state transitions.

I can access other (I do not how to call them) elements in the transition such as "effect" and "guard". To get the Trigger I have tried many transformations without any success.

I am not sure if this is important but if in a transition I do a:
self.ownedElement.size()

I get only 2 (guard, effect) elements instead of 3 (guard, effect and trigger).

I am not UML savy, so probably I am doing a very silly mistake. Any ideas?

thanks,
Arturo S.
Re: MOFScript and UML State machines [message #580144 is a reply to message #580123] Thu, 05 November 2009 11:53 Go to previous message
Gøran K. Olsen is currently offline Gøran K. Olsen
Messages: 184
Registered: July 2009
Senior Member
Hello Arturo,

Does the following transformation?

uml.Transition::test(){
self.trigger->forEach(trigg:uml.Trigger){
trigg.triggerTest()
}
}
uml.Trigger::triggerTest(){
self.name
}

Cheers,
G
Previous Topic:[MOFScript] Is there any way of configuring MOF Script to load metamodels from different paths?
Next Topic:MOFScript and UML State machines
Goto Forum:
  


Current Time: Mon Sep 22 04:29:45 GMT 2014

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

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