Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » Problem: No resource found, unable to extract..
Problem: No resource found, unable to extract.. [message #468251] Tue, 04 August 2009 17:40
Eclipse UserFriend
Originally posted by: valerio.cosentino.gmail.com

Hi,
i have two input metamodels (BPMN and UML2), and one simple output
metamodel:

Gambuse
+ Classifier
Name (String)
Type (String)
+ Disparity
Name (String)
c1 (Classifier)
c2 (Classifier)
+ Uguality
Name (String)
c1 (Classifier)
c2 (Classifier)

i wrote an atl file modelmatching.atl

module modelmatching;
create OUT : Gambuse from IN1 : BPMN, IN2 : UML2;

helper context BPMN!Activity def: isEmpty() : Boolean =
if self.name.oclIsUndefined() then
true
else
false
endif;

helper context UML2!NamedElement def: isEmpty() : Boolean =
if self.name.oclIsUndefined() then
true
else
false
endif;

rule BPMNtoGambuse {
from
s : BPMN!Activity (not s.isEmpty())
to
t : Gambuse!Classifier (
name <- s.name.toLower(),
type <- 'BPMN'

)
}

rule UML2toGambuse {
from
s : UML2!NamedElement (not s.isEmpty())
to
t : Gambuse!Classifier (
name <- s.name.toLower(),
type <- 'UML2'
)
}

rule FillIguality (s1 : BPMN!Activity, s2 : UML2!NamedElement) {
to
t : Gambuse!Iguality (
name <- s1.name+' '+s2.name,
c1 <- s1,
c2 <- s2
)
}

the rules BPMNtoGambuse and UML2toGambuse work fine and write in my output
file modelmatching.ecore:

<?xml version="1.0" encoding="ISO-8859-1"?>
<xmi:XMI xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI" xmlns="Gambuse">
<Classifier name="request catolog " type="BPMN"/>
<Classifier name="start event" type="BPMN"/>
<Classifier name="select products" type="BPMN"/>
<Classifier name="received po ack" type="BPMN"/>
<Classifier name="products order " type="BPMN"/>
<Classifier name="select payment method" type="BPMN"/>
...

but the last rule seem does not work, nothing appears in the output file
and atl generate an error:
No Resource found, unable to extract to file:/C:\Documents and
Settings\...\ModelMatching\modelmatching.ecore
Previous Topic:QVTO metamodel location
Next Topic:write a atl rule
Goto Forum:
  


Current Time: Thu Apr 25 08:01:55 GMT 2024

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

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

Back to the top