Hi all,
I have an ecore model with Process class containing variable class with Variables association name and partnerLink class with partnerLinks association name as shown below.
|--{Variables}--> |variable|
|Process| <composite>
|--{partnerLinks}--> |partnerLink|
The respective XMI instance looks like this
<BPEL:Process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"name="ManRoleType" targetNameSpace="http://abc.com">
<variables name="POChannelInstance"/>
<variables name="CPUnotInStock"/>
<partnerLinks name="CustRoleType"/>
<partnerLinks name="SupCPURoleType"/>
</BPEL:Process>
I am using AM3 extractor to generate an XML document which looks like this
<process >
<partnerLinks>
<partnerLink name=CustRoleType />
<partnerLink name=SupCPURoleType/>
</partnerLinks>
<varilables>
<varilable name= POChannelInstance/>
<varilable name= CPUnotInStock/>
</varilables>
</process>
Now, my problem is how can I specify those relationnames namely partnerLinks and variables into as an Element of XML.?
Following ATL code does not help.
rule Process2Root{
from
s : BPEL!Process
to
t : XML!Root(
name <- 'process',
children <- Sequence{xmlns, name, partnerLinks}
),
xmlns : XML!Attribute(
name <- 'xmlns',
value <- 'http://docs.oasis-open.org/wsbpel/2.0/process/executable'
),
name : XML!Attribute(
name <- 'name',
value <- s.name ),
partnerLinks: XML!Element(
name <- 'partnerLinks'
)
}
rule prtnerlinks2Elements (
from s: BPEL!PartnerLinks <!-- This is error now as BPEL metamodle does not have PartnerLinks as class -->
)
How should I work out to make partnerLinks and variables as elemtents that contains partnerlink and variable respectively?
Thanks
[Updated on: Sun, 15 August 2010 06:07]
Report message to a moderator