Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » [ATL] check attributes from other classes
[ATL] check attributes from other classes [message #546204] Mon, 12 July 2010 07:36 Go to next message
Roger80  is currently offline Roger80
Messages: 79
Registered: May 2010
Member
Hi again

I try to do a EPC to BPMN model transformation.
Now, I try to check if the former element was a Connector (Gateway) element or not. I try to do this with a helper.

I want to check this with the class Arc, as the class Arc always shows me the flow 'from' element 'to' element. So, if the source of the flow is a gateway I take another rule than if not.

Thus I tried to do create a helper, but my knowledge is really limited, in other words I am a rookie. Sad

That's what I want to do, more pseudo code.

helper context EPK!ControlFlow def: connectorBefore() : Boolean =
	if self.source = Check all connetcor classes if their id are the id in the source (AND.id or XOR.id or OR.id)  then
		true
	else
		false
	endif;
Re: [ATL] check attributes from other classes [message #546213 is a reply to message #546204] Mon, 12 July 2010 08:00 Go to previous message
Vincent MAHE is currently offline Vincent MAHE
Messages: 129
Registered: July 2009
Senior Member
Le 12/07/2010 09:36, Roger80 a écrit :
> Hi again
>
> I try to do a EPC to BPMN model transformation. Now, I try to check if
> the former element was a Connector (Gateway) element or not. I try to do
> this with a helper.
>
> I want to check this with the class Arc, as the class Arc always shows
> me the flow 'from' element 'to' element. So, if the source of the flow
> is a gateway I take another rule than if not.
>
> Thus I tried to do create a helper, but my knowledge is really limited,
> in other words I am a rookie. :(
>
> That's what I want to do, more pseudo code.
>
>
> helper context EPK!ControlFlow def: connectorBefore() : Boolean =
> if self.source = Check all connetcor classes if their id are the id in

You may use the AllInstances method on the Connector class

> the source (AND.id or XOR.id or OR.id) then
> true
> else
> false
> endif;
>


--
Cordialement

Vincent MAHÉ

Ingénieur Expert - Projet IDM++ - Équipe AtlanMod
École des Mines de Nantes
La Chantrerie - 4, rue Alfred Kastler
B.P. 20722 - F-44307 NANTES Cedex 3
Tel: (33)2 51 85 81 00
Previous Topic:[ATL] using weaving models with ATL 3.1.0
Next Topic:Starting Transformation pogrammatically
Goto Forum:
  


Current Time: Wed Oct 01 20:38:17 GMT 2014

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

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