Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » ATL:Transformation
ATL:Transformation [message #74977] Thu, 14 February 2008 10:57 Go to next message
Eclipse UserFriend
Originally posted by: ouldkonissa.yahoo.fr

Hello,
I am doing a transformation of JPDL to BlueXml.
The rule is

rule Swimlane2BPMActor{
from e : JPDL!Swimlane
to out : BlueXML!BPMActor(
assignment<- if e.assignment.oclIsUndefined() then
''
else e.assignment.pooledactors
endif,
name<-e.name,

manage <- if JPDL!Task.allInstances()->size()>0 then
JPDL!Task.allInstances()->select(t|t.swimlane <>
OclUndefined)->select(t|t.swimlane.name = e.name)-> asSequence()
else
Sequence{}
endif
)
}


In the result i obtain

<profileset xsi:type="MMUseCase:BPMActor"
xmi:id="_0PlasdrpEdyWevM8ojuhEA" name="initiator" assignment="">

the problem is that in the three first manage i obtain a 'href' in

<manage
href=" platform:/resource/BlueXml/JPDL2BlueXML/TransfoXmlToJpdl.eco re#//@startstate/@task "/>
<manage
href=" /BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl#_0Pi-cdrpEdyW evM8ojuhEA "/>
<manage
href=" /BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl#_0Pi-ctrpEdyW evM8ojuhEA "/>
</profileset>

instead of having an xmi : id
<profileset xsi:type="MMUseCase:BPMActor"
xmi:id="_0PpsINrpEdyWevM8ojuhEA" name="marketing"
manage="_0PiXYNrpEdyWevM8ojuhEA" assignment=""/>
<profileset xsi:type="MMUseCase:BPMActor"
xmi:id="_0PpsIdrpEdyWevM8ojuhEA" name="engineering"
manage="_0Pi-cNrpEdyWevM8ojuhEA" assignment=""/>


Thanks

Issa Koné
---
Re: ATL:Transformation [message #75041 is a reply to message #74977] Fri, 15 February 2008 12:00 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: quentin.glineur.obeo.fr

This is a multi-part message in MIME format.
--------------070904000503040005000504
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit

Hi Issa,

Is the resulting model valid ? I mean, is it just a matter of
serialization or are facing a problem with the model structure ?

Quentin GLINEUR

issa kone a
Re: ATL:Transformation [message #75047 is a reply to message #74977] Fri, 15 February 2008 12:12 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: r.c.ladan.tue.nl

issa kone wrote:
> Hello,
> I am doing a transformation of JPDL to BlueXml.
> The rule is
>
> rule Swimlane2BPMActor{
> from e : JPDL!Swimlane
> to out : BlueXML!BPMActor(
> assignment<- if e.assignment.oclIsUndefined() then
> ''
> else
> e.assignment.pooledactors
> endif,
> name<-e.name,
>
> manage <- if JPDL!Task.allInstances()->size()>0 then
> JPDL!Task.allInstances()->select(t|t.swimlane <>
> OclUndefined)->select(t|t.swimlane.name =
> e.name)-> asSequence()
> else
> Sequence{}
> endif
> )
> }
>
>
> In the result i obtain
>
> <profileset xsi:type="MMUseCase:BPMActor"
> xmi:id="_0PlasdrpEdyWevM8ojuhEA" name="initiator" assignment="">
>
> the problem is that in the three first manage i obtain a 'href' in
>
> <manage
> href=" platform:/resource/BlueXml/JPDL2BlueXML/TransfoXmlToJpdl.eco re#//@startstate/@task "/>
>
> <manage
> href=" /BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl#_0Pi-cdrpEdyW evM8ojuhEA "/>
>
> <manage
> href=" /BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl#_0Pi-ctrpEdyW evM8ojuhEA "/>
>
> </profileset>
>
> instead of having an xmi : id
> <profileset xsi:type="MMUseCase:BPMActor"
> xmi:id="_0PpsINrpEdyWevM8ojuhEA" name="marketing"
> manage="_0PiXYNrpEdyWevM8ojuhEA" assignment=""/>
> <profileset xsi:type="MMUseCase:BPMActor"
> xmi:id="_0PpsIdrpEdyWevM8ojuhEA" name="engineering"
> manage="_0Pi-cNrpEdyWevM8ojuhEA" assignment=""/>
>
This looks like an issue with how EMF serializes the resulting model. It also happens when
there are references to elements in your resulting model for which the referenced elements only
exist in the input model.

HTH,
Rene
Re: ATL:Transformation [message #75062 is a reply to message #75041] Fri, 15 February 2008 13:16 Go to previous message
Eclipse UserFriend
Originally posted by: ouldkonissa.yahoo.fr

Hello Quentin,

the resulting model is vaild because i can open it with the sample ecore
editor after having registered the target meta model. But when i rename
the resulting model in xmi and open it with a text editor, i find this
result where i have an 'href' to the name of the target model instead
of having an xmi : id like the others.

href="/BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl

According to Rene Ladan it may be :

<<This looks like an issue with how EMF serializes the resulting model.
It also happens when
there are references to elements in your resulting model for which the
referenced elements only
exist in the input model.>>

Thanks for your reply.

Issa Koné



Quentin Glineur a écrit :
> Hi Issa,
>
> Is the resulting model valid ? I mean, is it just a matter of
> serialization or are facing a problem with the model structure ?
>
> Quentin GLINEUR
>
> issa kone a écrit :
>> Hello,
>> I am doing a transformation of JPDL to BlueXml.
>> The rule is
>>
>> rule Swimlane2BPMActor{
>> from e : JPDL!Swimlane
>> to out : BlueXML!BPMActor(
>> assignment<- if e.assignment.oclIsUndefined() then
>> ''
>> else
>> e.assignment.pooledactors
>> endif,
>> name<-e.name,
>> manage <- if JPDL!Task.allInstances()->size()>0 then
>> JPDL!Task.allInstances()->select(t|t.swimlane <>
>> OclUndefined)->select(t|t.swimlane.name
>> = e.name)-> asSequence()
>> else
>> Sequence{}
>> endif
>> ) }
>>
>>
>> In the result i obtain
>>
>> <profileset xsi:type="MMUseCase:BPMActor"
>> xmi:id="_0PlasdrpEdyWevM8ojuhEA" name="initiator" assignment="">
>>
>> the problem is that in the three first manage i obtain a 'href' in
>>
>> <manage
>> href=" platform:/resource/BlueXml/JPDL2BlueXML/TransfoXmlToJpdl.eco re#//@startstate/@task "/>
>>
>> <manage
>> href=" /BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl#_0Pi-cdrpEdyW evM8ojuhEA "/>
>>
>> <manage
>> href=" /BlueXml/JPDL2BlueXML/TransfoJpdlToBlueXml.obl#_0Pi-ctrpEdyW evM8ojuhEA "/>
>>
>> </profileset>
>>
>> instead of having an xmi : id
>> <profileset xsi:type="MMUseCase:BPMActor"
>> xmi:id="_0PpsINrpEdyWevM8ojuhEA" name="marketing"
>> manage="_0PiXYNrpEdyWevM8ojuhEA" assignment=""/>
>> <profileset xsi:type="MMUseCase:BPMActor"
>> xmi:id="_0PpsIdrpEdyWevM8ojuhEA" name="engineering"
>> manage="_0Pi-cNrpEdyWevM8ojuhEA" assignment=""/>
>>
>>
>> Thanks
>>
>> Issa Koné
>> ---
>
Previous Topic:[ATL] Run ant script via console
Next Topic:[ATL] MagicDraw and ATL
Goto Forum:
  


Current Time: Mon Aug 19 04:23:06 GMT 2019

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

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

Back to the top