Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » AMW » Model combination.
Model combination. [message #468661] Wed, 19 November 2008 11:48 Go to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------090800030108040203080807
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Hi Marcos and everybody.
I'm trying to use AMW for the first time, and I believe I could use some
help from people with more knowledge of it than me.

I would like to use AMW to combine models (in a sort of Aspect-Oriented
Modeling). I have a Model 'IN1' corresponding to Meta-Model "A"
(something like a simpler version of UML), and a second model "IN2",
that is a security model that corresponds to SecureUML metamodel. I
wanted to combine this two models into a target model that corresponds
to a metamodel that is the result of the merging of the first two (see
the attached picture). This "combination" of the models is more than a
mere merging.

How could I do this?. In the use cases I saw from the website there is
always one input model and some matching rules to generate one output
model (sort of as in a simple ATL transformation).
I tried using the wizard declaring two input models (IN1 and IN2) and
the output metamodel, but when it comes to choosing the input, I can
only choose one element from either one of the input models.

I believe I'm missing the big picture here, and I surely need some
advice to get going.
Any help will be greatly appreciated.
Regards,
Juan Pedro


--------------090800030108040203080807
Content-Type: image/jpeg;
name="eXAMPLE.JPG"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="eXAMPLE.JPG"

/9j/4AAQSkZJRgABAQEAYABgAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsL DBkSEw8UHRof
Hh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwL DBgNDRgyIRwh
MjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy MjIyMjL/wAAR
CAF/AaIDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcI CQoL/8QAtRAA
AgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS 0fAkM2JyggkK
FhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1 dnd4eXqDhIWG
h4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW 19jZ2uHi4+Tl
5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcI CQoL/8QAtREA
AgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMz UvAVYnLRChYk
NOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0 dXZ3eHl6goOE
hYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU 1dbX2Nna4uPk
5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwD3+iiigAooooAKKKKACiii gAooooAKKKKA
CiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAK KKKACiiigAoo
ooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiii gAooooAKKKKA
CiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAK KKKACiiigAoo
ooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKK4fwn4b tNT8G6Hf3l9r
kl1dafbzTP8A25eDc7RqWOBLgZJPSgDuKK5//hDdL/5+tc/8Ht7/APHqP+EN 0v8A5+tc/wDB
7e//AB6gDoKK5/8A4Q3S/wDn61z/AMHt7/8AHqP+EN0v/n61z/we3v8A8eoA 6Ciuf/4Q3S/+
frXP/B7e/wDx6j/hDdL/AOfrXP8Awe3v/wAeoA6Ciuf/AOEN0v8A5+tc/wDB 7e//AB6j/hDd
L/5+tc/8Ht7/APHqAOgorn/+EN0v/n61z/we3v8A8eo/4Q3S/wDn61z/AMHt 7/8AHqAOgorn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COtbGi6SmiaYLKO5nuf3sszzT7d7v JI0jE7VVfvOe
gFAGhRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQBwdz4ahfxHY6bd3Ekk9 7pmpTXF5GAkn
nNPZkSITkqYyEEeSxQRxjJ2g13EAmW3iW4kjknCASPGhRWbHJCkkgZ7ZOPU1 h3n/ACUPRv8A
sFX/AP6NtK6CgAooooAKKKKACiiigAooooAz9Y0z+2LNLOSbZatKjXKBcmaN TuMfXG1iAGBB
DIWXHzZHP+E9M3H+1YZvKkTUNUt7hNuRPGb2Zlzgj5kYZUnIAeQYy+R2Fc/4 N/5Adz/2FdS/
9LZqAOgooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooA KKKKACiiigAr
j/iDpn2jwzruozTbo7XRLxbeDbwsjxMGkJJ5YKNqkAFQ8gyQ+B2Fc/47/wCS eeJf+wVdf+im
oA0NP0z+zry/eKbNrdyi4WDbgQyEYk2nONrEB8YzvaRiTuwNCiigAooooAKK KKACiiigAooo
oAKKKKACiiigAooooA5+8/5KHo3/AGCr/wD9G2ldBXP3n/JQ9G/7BV//AOjb SugoAKKKKACi
iigAooooAKKKKACuf8G/8gO5/wCwrqX/AKWzV0Fc/wCDf+QHc/8AYV1L/wBL ZqAOgooooAKK
KKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigArn/ AB3/AMk88S/9
gq6/9FNXQVz/AI7/AOSeeJf+wVdf+imoA6CiiigAooooAKKKKACiiigAoooo AKKKKACiiigA
ooooA5+8/wCSh6N/2Cr/AP8ARtpXQVz95/yUPRv+wVf/APo20roKACiiigAo oooAKKKKACii
igArn/Bv/IDuf+wrqX/pbNXQVz/g3/kB3P8A2FdS/wDS2agDoKKKKACiiigA ooooAKKKKACi
iigAooooAKKKKACiiigAooooAKKKKACiiigAooooAK5/x3/yTzxL/wBgq6/9 FNXQVz/jv/kn
niX/ALBV1/6KagDoKKKKACiiigAooooAKKz9Th1iXyv7JvrG1xnzP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UUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUU UAFFFFABRRRQ
AUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFAB RRRQAUUUUAFF
FFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUU UAFFFFABRRRQ
B//Z
--------------090800030108040203080807--
Re: Model combination. [message #468673 is a reply to message #468661] Wed, 19 November 2008 12:19 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
Hello,


In aspect oriented modeling, the metamodels are combined. It would be
the creation of MMA + SecureUML metamodel based on links between MMA and
SecureUML.

Your case seems more similar to the "Merge of geographical data" use
case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.

This is a complex case, where the generated transformation must take two
models as input and produce one model as output. You need a special
extension of AMW to support this kind of scenario. Take a look on this
use case to see if you can get some inspiration. :) Let me know if you
have any other questions.

Regards,

Marcos.

Juan Pedro Silva wrote:
> Hi Marcos and everybody.
> I'm trying to use AMW for the first time, and I believe I could use some
> help from people with more knowledge of it than me.
>
> I would like to use AMW to combine models (in a sort of Aspect-Oriented
> Modeling). I have a Model 'IN1' corresponding to Meta-Model "A"
> (something like a simpler version of UML), and a second model "IN2",
> that is a security model that corresponds to SecureUML metamodel. I
> wanted to combine this two models into a target model that corresponds
> to a metamodel that is the result of the merging of the first two (see
> the attached picture). This "combination" of the models is more than a
> mere merging.
>
> How could I do this?. In the use cases I saw from the website there is
> always one input model and some matching rules to generate one output
> model (sort of as in a simple ATL transformation).
> I tried using the wizard declaring two input models (IN1 and IN2) and
> the output metamodel, but when it comes to choosing the input, I can
> only choose one element from either one of the input models.
>
> I believe I'm missing the big picture here, and I surely need some
> advice to get going.
> Any help will be greatly appreciated.
> Regards,
> Juan Pedro
>
>
> ------------------------------------------------------------ ------------
>
Re: Model combination. [message #469155 is a reply to message #468673] Fri, 23 January 2009 10:14 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Marcos, I'm back to this after some time doing some other stuff.<br>
I have a doubt regarding how to link the semantics of the
transformation with the definition of the weaving metamodel extensions.<br>
<br>
For example, I define the following extension (I based it on the AOM
use case):<br>
<font color="#3366ff"><small><br>
<font face="Courier New, Courier, monospace">class ResourceCombination&nbsp;
extends WLink {</font><br>
<font face="Courier New, Courier, monospace">&nbsp;&nbsp;&nbsp; -- @subsets end</font><br>
<font face="Courier New, Courier, monospace">&nbsp;&nbsp;&nbsp; reference
targetResource [*] container : </font></small><small><font
face="Courier New, Courier, monospace">Resource</font></small><small><font
face="Courier New, Courier, monospace">;</font><br>
<font face="Courier New, Courier, monospace">&nbsp;&nbsp;&nbsp; </font><br>
<font face="Courier New, Courier, monospace">&nbsp;&nbsp;&nbsp; -- @subsets end</font><br>
<font face="Courier New, Courier, monospace">&nbsp;&nbsp;&nbsp; reference
createActions [*] container : </font></small><small><font
face="Courier New, Courier, monospace">Resource</font></small></font><small><font
color="#3366ff" face="Courier New, Courier, monospace">;</font><font
color="#3366ff"><br>
</font><font color="#3366ff" face="Courier New, Courier, monospace">&nbsp;&nbsp;&nbsp;
</font><font color="#3366ff"><br>
</font><font color="#3366ff" face="Courier New, Courier, monospace">} </font><font
color="#3366ff"><br>
</font><font color="#3366ff" face="Courier New, Courier, monospace">class
Resource extends WLinkEnd {</font><font color="#3366ff"><br>
</font><font color="#3366ff" face="Courier New, Courier, monospace">}</font><br>
</small><br>
and now I want to express that, when I draw a "ResourceCombination"
link, every action that exists on the "<small><font
face="Courier New, Courier, monospace">createActions</font></small>"
Resource should be created in the "targetResource" Resource (I want to
do more complicated things with it, but lets start with this). <br>
In atl, such rule would be:<br>
<small><font face="Courier New, Courier, monospace"><br>
<font color="#3366ff">rule ActionsToResource&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; --My guess is that the rule name doesn't affect<br>
{<br>
&nbsp;&nbsp;&nbsp; from <br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; cO : MMA!Resource<br>
&nbsp;&nbsp;&nbsp; to <br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; out : MMB!</font></font></small><small><font
face="Courier New, Courier, monospace"><font color="#3366ff">Resource</font></font></small><small><font
face="Courier New, Courier, monospace"><font color="#3366ff"> <br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; (<br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; action &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &lt;-&nbsp;&nbsp;&nbsp; cO.action&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; --where
"action" is a set of "Action" elements &nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; <br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; )<br>
}<br>
<br>
</font></font></small>What I don't know how to do is to associate the
weaving model (.amw) with the transformation rules (.atl), in order to
apply the weavings.<br>
How does the linking of the amw extensions with the rules takes place?.<br>
Thank you very much.<br>
Regards,<br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Juan Pedro<br>
<br>
<br>
<br>
Marcos Didonet Del Fabro escribi&oacute;:
<blockquote cite="mid:gg1hrd$qjn$1@build.eclipse.org" type="cite">Hello,
<br>
<br>
<br>
In aspect oriented modeling, the metamodels are combined. It would be
the creation of MMA + SecureUML metamodel based on links between MMA
and SecureUML.
<br>
<br>
Your case seems more similar to the "Merge of geographical data" use
case. <a class="moz-txt-link-freetext" href="http://www.eclipse.org/gmt/amw/usecases/mergeSVG/">http://www.eclipse.org/gmt/amw/usecases/mergeSVG/</a>.
<br>
<br>
This is a complex case, where the generated transformation must take
two models as input and produce one model as output. You need a special
extension of AMW to support this kind of scenario. Take a look on this
use case to see if you can get some inspiration. :) Let me know if you
have any other questions.
<br>
<br>
Regards,
<br>
<br>
Marcos.
<br>
<br>
Juan Pedro Silva wrote:
<br>
<blockquote type="cite">Hi Marcos and everybody.
<br>
I'm trying to use AMW for the first time, and I believe I could use
some help from people with more knowledge of it than me.
<br>
<br>
I would like to use AMW to combine models (in a sort of Aspect-Oriented
Modeling). I have a Model 'IN1' corresponding to Meta-Model "A"
(something like a simpler version of UML), and a second model "IN2",
that is a security model that corresponds to SecureUML metamodel. I
wanted to combine this two models into a target model that corresponds
to a metamodel that is the result of the merging of the first two (see
the attached picture). This "combination" of the models is more than a
mere merging.
<br>
<br>
How could I do this?. In the use cases I saw from the website there is
always one input model and some matching rules to generate one output
model (sort of as in a simple ATL transformation).
<br>
I tried using the wizard declaring two input models (IN1 and IN2) and
the output metamodel, but when it comes to choosing the input, I can
only choose one element from either one of the input models.
<br>
<br>
I believe I'm missing the big picture here, and I surely need some
advice to get going.
<br>
Any help will be greatly appreciated.
<br>
Regards,
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Juan Pedro
<br>
<br>
<br>
------------------------------------------------------------ ------------
<br>
<br>
</blockquote>
</blockquote>
</body>
</html>
Re: Model combination. [message #469160 is a reply to message #469155] Tue, 27 January 2009 11:13 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
Hello,

I didn't understand what you mean by "linking the rules with ATL".

You can set the weaving model as input (or output) in the ATL
transformation, and than use it in different ways. I depict some below:

The signature of the transformation would be the following:

module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;

1) Matching the weaving link + the target actions:

rule MatchLink {

from
link : AMW!ResourceCombination, resource : MMA!Resource (some
condition to verify the correct input resource )

to
out : MMB!Resource (
action <- -- check for the target resource actions
-- see the AMW model handler Wiki
(http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check how the
getReffered() method works)
)

}

2) you can create the rule similar as the one you have, and search for
the linked elements.

rule ActionsToResource {
from
cO : MMA!Resource
to
out : MMB!Resource
(
action <- cO.getOutputActions() -- The helper is created
for better readability.
)
}


helper context MMA!Resource getOutputActions() : Sequence (MMA!Action) =
-- the helper should search for the ResourceCombination links and
that returns the model elements based on the values of the references
targetResource and createAction.


Regards,

Marcos.



Juan Pedro Silva wrote:
> Marcos, I'm back to this after some time doing some other stuff.
> I have a doubt regarding how to link the semantics of the transformation
> with the definition of the weaving metamodel extensions.
>
> For example, I define the following extension (I based it on the AOM use
> case):
>
> class ResourceCombination extends WLink {
> -- @subsets end
> reference targetResource [*] container : Resource;
>
> -- @subsets end
> reference createActions [*] container : Resource;
>
> }
> class Resource extends WLinkEnd {
> }
>
> and now I want to express that, when I draw a "ResourceCombination"
> link, every action that exists on the "createActions" Resource should be
> created in the "targetResource" Resource (I want to do more complicated
> things with it, but lets start with this).
> In atl, such rule would be:
>
> rule ActionsToResource --My guess
> is that the rule name doesn't affect
> {
> from
> cO : MMA!Resource
> to
> out : MMB!Resource
> (
> action <- cO.action --where
> "action" is a set of "Action" elements
> )
> }
>
> What I don't know how to do is to associate the weaving model (.amw)
> with the transformation rules (.atl), in order to apply the weavings.
> How does the linking of the amw extensions with the rules takes place?.
> Thank you very much.
> Regards,
> Juan Pedro
>
>
>
> Marcos Didonet Del Fabro escribió:
>> Hello,
>>
>>
>> In aspect oriented modeling, the metamodels are combined. It would be
>> the creation of MMA + SecureUML metamodel based on links between MMA
>> and SecureUML.
>>
>> Your case seems more similar to the "Merge of geographical data" use
>> case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>
>> This is a complex case, where the generated transformation must take
>> two models as input and produce one model as output. You need a
>> special extension of AMW to support this kind of scenario. Take a look
>> on this use case to see if you can get some inspiration. :) Let me
>> know if you have any other questions.
>>
>> Regards,
>>
>> Marcos.
>>
>> Juan Pedro Silva wrote:
>>> Hi Marcos and everybody.
>>> I'm trying to use AMW for the first time, and I believe I could use
>>> some help from people with more knowledge of it than me.
>>>
>>> I would like to use AMW to combine models (in a sort of
>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding to
>>> Meta-Model "A" (something like a simpler version of UML), and a
>>> second model "IN2", that is a security model that corresponds to
>>> SecureUML metamodel. I wanted to combine this two models into a
>>> target model that corresponds to a metamodel that is the result of
>>> the merging of the first two (see the attached picture). This
>>> "combination" of the models is more than a mere merging.
>>>
>>> How could I do this?. In the use cases I saw from the website there
>>> is always one input model and some matching rules to generate one
>>> output model (sort of as in a simple ATL transformation).
>>> I tried using the wizard declaring two input models (IN1 and IN2) and
>>> the output metamodel, but when it comes to choosing the input, I can
>>> only choose one element from either one of the input models.
>>>
>>> I believe I'm missing the big picture here, and I surely need some
>>> advice to get going.
>>> Any help will be greatly appreciated.
>>> Regards,
>>> Juan Pedro
>>>
>>>
>>> ------------------------------------------------------------ ------------
>>>
Re: Model combination. [message #469162 is a reply to message #469160] Thu, 29 January 2009 09:38 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------010809020301050802000102
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Marcos, sorry for not being clear.<br>
Your answer is of great help to manually generate the transformations.
I'm currently generating the weaving model manually, but it will take
some time to finish due to the size (moderate, but not small) of the
metamodels. After that I'll give this a try.<br>
&nbsp;<br>
I was referring to the HOT (or "transfGen", as you call it in your phd
Thesis).<br>
I'm having problems with the automatic generation of the
transformation, in various steps.<br>
What I'm trying to do at this point (I postponed the combination of
models until I get this right) is:<br>
<ol>
<li>An automatic Matching model (as in&nbsp; the "Metamodel comparison use
case") for my own metamodels.<br>
</li>
<li>Manually tune this model with some other wlink extensions
(previously loading my km3 extension).</li>
<li>Generate the ATL transformation (HOT) by means of the AMW context
menu option.</li>
</ol>
However, I'm getting errors in step 1. I can execute the "Metamodel
Match -&gt; Cartesian Product" (takes long but works), but I get errors
when running the "Name Equality" on the cp result (I'm attaching the
console output). I also get an error while trying step 3 on a partial
weaving model, but as the weaving model was partial and manual, I'll
wait until it is complete and try again.<br>
<br>
The question would be, are there any conditions on the metamodels in
order for the matching to work?, and is the available HOT general
enough for using it with our own weaving-metamodel extensions, or I am
supposed to make my own HOTs for them?.<br>
<br>
Thanks again, Marcos.<br>
Regards,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; Juan Pedro<br>
<br>
<br>
<br>
Marcos Didonet Del Fabro escribi&oacute;:
<blockquote cite="mid:glnbrk$76u$1@build.eclipse.org" type="cite"><br>
Hello,
<br>
<br>
I didn't understand what you mean by "linking the rules with ATL".
<br>
<br>
You can set the weaving model as input (or output) in the ATL
transformation, and than use it in different ways. I depict some below:
<br>
<br>
The signature of the transformation would be the following:
<br>
<br>
module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
<br>
<br>
1) Matching the weaving link + the target actions:
<br>
<br>
rule MatchLink {
<br>
<br>
from
<br>
&nbsp; link : AMW!ResourceCombination, resource : MMA!Resource (some
condition to verify the correct input resource )
<br>
<br>
to
<br>
&nbsp; out : MMB!Resource (
<br>
&nbsp;&nbsp;&nbsp;&nbsp; action &lt;- -- check for the target resource actions
<br>
&nbsp;&nbsp;&nbsp;&nbsp; -- see the AMW model handler Wiki
(<a class="moz-txt-link-freetext" href="http://wiki.eclipse.org/index.php/AMW_Model_Handler">http://wiki.eclipse.org/index.php/AMW_Model_Handler</a>) to check how the
getReffered() method works)
<br>
&nbsp; )
<br>
<br>
}
<br>
<br>
2) you can create the rule similar as the one you have, and search for
the linked elements.
<br>
<br>
rule ActionsToResource {
<br>
&nbsp;&nbsp;&nbsp;&nbsp; from
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; cO : MMA!Resource
<br>
&nbsp;&nbsp;&nbsp;&nbsp; to
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; out : MMB!Resource
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; (
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; action&nbsp; &lt;- cO.getOutputActions() -- The helper is
created for better readability.
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; )
<br>
&nbsp;}
<br>
<br>
<br>
helper context MMA!Resource getOutputActions() : Sequence (MMA!Action)
=
<br>
&nbsp;&nbsp; -- the helper should search for the ResourceCombination links and
that returns the model elements based on the values of the references
targetResource and createAction.
<br>
<br>
<br>
Regards,
<br>
<br>
Marcos.
<br>
<br>
<br>
<br>
Juan Pedro Silva wrote:
<br>
<blockquote type="cite">Marcos, I'm back to this after some time
doing some other stuff.
<br>
I have a doubt regarding how to link the semantics of the
transformation with the definition of the weaving metamodel extensions.
<br>
<br>
For example, I define the following extension (I based it on the AOM
use case):
<br>
<br>
class ResourceCombination&nbsp; extends WLink {
<br>
&nbsp;&nbsp;&nbsp; -- @subsets end
<br>
&nbsp;&nbsp;&nbsp; reference targetResource [*] container : Resource;
<br>
&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; -- @subsets end
<br>
&nbsp;&nbsp;&nbsp; reference createActions [*] container : Resource;
<br>
&nbsp;&nbsp; }
<br>
class Resource extends WLinkEnd {
<br>
}
<br>
<br>
and now I want to express that, when I draw a "ResourceCombination"
link, every action that exists on the "createActions" Resource should
be created in the "targetResource" Resource (I want to do more
complicated things with it, but lets start with this).
<br>
In atl, such rule would be:
<br>
<br>
rule ActionsToResource&nbsp;&nbsp;&nbsp;&nbsp;&am p;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&am p;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&am p;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&am p;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&am p;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&am p;nbsp;&nbsp;&nbsp; --My guess
is that the rule name doesn't affect
<br>
{
<br>
&nbsp;&nbsp;&nbsp; from
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; cO : MMA!Resource
<br>
&nbsp;&nbsp;&nbsp; to
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; out : MMB!Resource
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; (
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; action&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;& ;nbsp;&nbsp;&nbsp; &lt;-&nbsp;&nbsp;&nbsp; cO.action&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;& amp;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;& amp;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; --where
"action" is a set of "Action" elements&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&a mp;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&a mp;nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&a mp;nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; )
<br>
}
<br>
<br>
What I don't know how to do is to associate the weaving model (.amw)
with the transformation rules (.atl), in order to apply the weavings.
<br>
How does the linking of the amw extensions with the rules takes place?.
<br>
Thank you very much.
<br>
Regards,
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; Juan Pedro
<br>
<br>
<br>
<br>
Marcos Didonet Del Fabro escribi&oacute;:
<br>
<blockquote type="cite">Hello,
<br>
<br>
<br>
In aspect oriented modeling, the metamodels are combined. It would be
the creation of MMA + SecureUML metamodel based on links between MMA
and SecureUML.
<br>
<br>
Your case seems more similar to the "Merge of geographical data" use
case. <a class="moz-txt-link-freetext" href="http://www.eclipse.org/gmt/amw/usecases/mergeSVG/">http://www.eclipse.org/gmt/amw/usecases/mergeSVG/</a>.
<br>
<br>
This is a complex case, where the generated transformation must take
two models as input and produce one model as output. You need a special
extension of AMW to support this kind of scenario. Take a look on this
use case to see if you can get some inspiration. :) Let me know if you
have any other questions.
<br>
<br>
Regards,
<br>
<br>
Marcos.
<br>
<br>
Juan Pedro Silva wrote:
<br>
<blockquote type="cite">Hi Marcos and everybody.
<br>
I'm trying to use AMW for the first time, and I believe I could use
some help from people with more knowledge of it than me.
<br>
<br>
I would like to use AMW to combine models (in a sort of Aspect-Oriented
Modeling). I have a Model 'IN1' corresponding to Meta-Model "A"
(something like a simpler version of UML), and a second model "IN2",
that is a security model that corresponds to SecureUML metamodel. I
wanted to combine this two models into a target model that corresponds
to a metamodel that is the result of the merging of the first two (see
the attached picture). This "combination" of the models is more than a
mere merging.
<br>
<br>
How could I do this?. In the use cases I saw from the website there is
always one input model and some matching rules to generate one output
model (sort of as in a simple ATL transformation).
<br>
I tried using the wizard declaring two input models (IN1 and IN2) and
the output metamodel, but when it comes to choosing the input, I can
only choose one element from either one of the input models.
<br>
<br>
I believe I'm missing the big picture here, and I surely need some
advice to get going.
<br>
Any help will be greatly appreciated.
<br>
Regards,
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Juan Pedro
<br>
<br>
<br>
------------------------------------------------------------ ------------
<br>
<br>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</body>
</html>

--------------010809020301050802000102
Content-Type: text/plain;
name="Error_Console.txt"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="Error_Console.txt"

GRAVE: ****** BEGIN Stack Trace
GRAVE: exception:
GRAVE: null
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.m2m.atl.engine.vm.ClassNativeOperation.exec(Clas sNativeOperation.java:69)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:143)
at org.eclipse.m2m.atl.drivers.emf4atl.ASMEMFModelElement.invok e(ASMEMFModelElement.java:683)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:240)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:335)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.exec(ASMOperation .java:171)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:143)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:101)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:240)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.exec(ASMOperation .java:171)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:143)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:101)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:240)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.exec(ASMOperation .java:171)
at org.eclipse.m2m.atl.engine.vm.ASMInterpreter.<init>(ASMInterpreter.java:299)
at org.eclipse.m2m.atl.engine.AtlLauncher.launch(AtlLauncher.ja va:167)
at org.eclipse.m2m.atl.engine.AtlLauncher.launch(AtlLauncher.ja va:111)
at org.eclipse.m2m.atl.engine.AtlLauncher.launch(AtlLauncher.ja va:87)
at org.eclipse.gmt.weaver.transformation.util.TransformationUti l.executeTransfo(TransformationUtil.java:103)
at org.eclipse.gmt.weaver.transformation.panel.TransformationWe avingPanel$TAction.run(TransformationWeavingPanel.java:181)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:498 )
at org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:583)
at org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:500)
at org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3422)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:2382)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2346)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:21 98)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:493)
at org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:288)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:488)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:113)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:193)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:386)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 549)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
Caused by: java.lang.NullPointerException
at org.eclipse.m2m.atl.drivers.emf4atl.ASMEMFModelElement.getMe taobject(ASMEMFModelElement.java:422)
at org.eclipse.m2m.atl.drivers.emf4atl.ASMEMFModelElement.<init >(ASMEMFModelElement.java:557)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.<init>(ASMAMWModelElement.java:43)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModel.getASMModelElemen t(ASMAMWModel.java:361)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.getModelEl ement(ASMAMWModelElement.java:159)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.getReferre dElement(ASMAMWModelElement.java:194)
... 52 more
GRAVE: A.main() : ??#22 null
GRAVE: local variables = {self=NameEqualitybyType : ASMModule}
GRAVE: local stack = []
GRAVE: A.__matcher__() : ??#1 null
GRAVE: local variables = {self=NameEqualitybyType : ASMModule}
GRAVE: local stack = []
GRAVE: A.__matchprClass() : ??#31 37:53-37:83
GRAVE: local variables = {left=left!UIComboBox, mmw=IN!UIComboBox_EAnnotation, self=NameEqualitybyType : ASMModule}
GRAVE: local stack = [TransientLinkSet {}, TransientLink {rule = 'prClass', sourceElements = {mmw = IN!UIComboBox_EAnnotation}, targetElements = {}, variables = {left = left!UIComboBox}}, TransientLink {rule = 'prClass', sourceElements = {mmw = IN!UIComboBox_EAnnotation}, targetElements = {}, variables = {left = left!UIComboBox}}, 'right']
GRAVE: NativeOperation public static org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.getReferre dElement(org.eclipse.m2m.atl.engine.vm.StackFrame,org.eclips e.m2m.atl.drivers.emf4atl.ASMEMFModelElement)
GRAVE: args = [IN!EAnnotation]
GRAVE: ****** END Stack Trace
INFO: Execution terminated due to error (see launch configuration to allow continuation after errors).
GRAVE: null
java.lang.RuntimeException
at org.eclipse.m2m.atl.engine.vm.SimpleDebugger.error(SimpleDeb ugger.java:195)
at org.eclipse.m2m.atl.engine.vm.StackFrame.printStackTrace(Sta ckFrame.java:95)
at org.eclipse.m2m.atl.engine.vm.StackFrame.printStackTrace(Sta ckFrame.java:87)
at org.eclipse.m2m.atl.engine.vm.ClassNativeOperation.exec(Clas sNativeOperation.java:77)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:143)
at org.eclipse.m2m.atl.drivers.emf4atl.ASMEMFModelElement.invok e(ASMEMFModelElement.java:683)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:240)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:335)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.exec(ASMOperation .java:171)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:143)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:101)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:240)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.exec(ASMOperation .java:171)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:143)
at org.eclipse.m2m.atl.engine.vm.nativelib.ASMOclAny.invoke(ASM OclAny.java:101)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.realExec(ASMOpera tion.java:240)
at org.eclipse.m2m.atl.engine.vm.ASMOperation.exec(ASMOperation .java:171)
at org.eclipse.m2m.atl.engine.vm.ASMInterpreter.<init>(ASMInterpreter.java:299)
at org.eclipse.m2m.atl.engine.AtlLauncher.launch(AtlLauncher.ja va:167)
at org.eclipse.m2m.atl.engine.AtlLauncher.launch(AtlLauncher.ja va:111)
at org.eclipse.m2m.atl.engine.AtlLauncher.launch(AtlLauncher.ja va:87)
at org.eclipse.gmt.weaver.transformation.util.TransformationUti l.executeTransfo(TransformationUtil.java:103)
at org.eclipse.gmt.weaver.transformation.panel.TransformationWe avingPanel$TAction.run(TransformationWeavingPanel.java:181)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:498 )
at org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:583)
at org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:500)
at org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3422)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:2382)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2346)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:21 98)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:493)
at org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:288)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:488)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:113)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:193)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:386)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 549)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.m2m.atl.engine.vm.ClassNativeOperation.exec(Clas sNativeOperation.java:69)
... 47 more
Caused by: java.lang.NullPointerException
at org.eclipse.m2m.atl.drivers.emf4atl.ASMEMFModelElement.getMe taobject(ASMEMFModelElement.java:422)
at org.eclipse.m2m.atl.drivers.emf4atl.ASMEMFModelElement.<init >(ASMEMFModelElement.java:557)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.<init>(ASMAMWModelElement.java:43)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModel.getASMModelElemen t(ASMAMWModel.java:361)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.getModelEl ement(ASMAMWModelElement.java:159)
at org.eclipse.gmt.weaver.amw4atl.ASMAMWModelElement.getReferre dElement(ASMAMWModelElement.java:194)
... 52 more

--------------010809020301050802000102--
Re: Model combination. [message #469545 is a reply to message #469162] Fri, 30 January 2009 03:54 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
Hello,

The matching transformations, as well as the corresponding HOTs, are
implemented based on specific extensions to the AMW core metamodel. If
you want to use new extensions, the HOT must be extended to be able to
support them.

To execute the matching transformations of the plug-in, the following
extensions are needed:
- mw_base_ext
- mmw_match (equality, cardinality, type and conformance, Cartesian
product, link rewriting, threshold)
- mm_propagation (SF, propagation graph)
- mmw_compare (not equivalence)

If you add new extensions, the transformations won't produce any
additional result, since they are not aware of the existence of new
types of links.

Now, looking at your error log, it seems that you don't have any element
associated to the "right" reference:

variables = {left = left!UIComboBox}}, 'right']

The transformations need to have the "left" and "right" references set
up in the weaving model.

Regards,

Marcos.


Juan Pedro Silva wrote:
> Hi Marcos, sorry for not being clear.
> Your answer is of great help to manually generate the transformations.
> I'm currently generating the weaving model manually, but it will take
> some time to finish due to the size (moderate, but not small) of the
> metamodels. After that I'll give this a try.
>
> I was referring to the HOT (or "transfGen", as you call it in your phd
> Thesis).
> I'm having problems with the automatic generation of the transformation,
> in various steps.
> What I'm trying to do at this point (I postponed the combination of
> models until I get this right) is:
>
> 1. An automatic Matching model (as in the "Metamodel comparison use
> case") for my own metamodels.
> 2. Manually tune this model with some other wlink extensions
> (previously loading my km3 extension).
> 3. Generate the ATL transformation (HOT) by means of the AMW context
> menu option.
>
> However, I'm getting errors in step 1. I can execute the "Metamodel
> Match -> Cartesian Product" (takes long but works), but I get errors
> when running the "Name Equality" on the cp result (I'm attaching the
> console output). I also get an error while trying step 3 on a partial
> weaving model, but as the weaving model was partial and manual, I'll
> wait until it is complete and try again.
>
> The question would be, are there any conditions on the metamodels in
> order for the matching to work?, and is the available HOT general enough
> for using it with our own weaving-metamodel extensions, or I am supposed
> to make my own HOTs for them?.
>
> Thanks again, Marcos.
> Regards,
> Juan Pedro
>
>
>
> Marcos Didonet Del Fabro escribió:
>>
>> Hello,
>>
>> I didn't understand what you mean by "linking the rules with ATL".
>>
>> You can set the weaving model as input (or output) in the ATL
>> transformation, and than use it in different ways. I depict some below:
>>
>> The signature of the transformation would be the following:
>>
>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>
>> 1) Matching the weaving link + the target actions:
>>
>> rule MatchLink {
>>
>> from
>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>> condition to verify the correct input resource )
>>
>> to
>> out : MMB!Resource (
>> action <- -- check for the target resource actions
>> -- see the AMW model handler Wiki
>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check how the
>> getReffered() method works)
>> )
>>
>> }
>>
>> 2) you can create the rule similar as the one you have, and search for
>> the linked elements.
>>
>> rule ActionsToResource {
>> from
>> cO : MMA!Resource
>> to
>> out : MMB!Resource
>> (
>> action <- cO.getOutputActions() -- The helper is created
>> for better readability.
>> )
>> }
>>
>>
>> helper context MMA!Resource getOutputActions() : Sequence (MMA!Action) =
>> -- the helper should search for the ResourceCombination links and
>> that returns the model elements based on the values of the references
>> targetResource and createAction.
>>
>>
>> Regards,
>>
>> Marcos.
>>
>>
>>
>> Juan Pedro Silva wrote:
>>> Marcos, I'm back to this after some time doing some other stuff.
>>> I have a doubt regarding how to link the semantics of the
>>> transformation with the definition of the weaving metamodel extensions.
>>>
>>> For example, I define the following extension (I based it on the AOM
>>> use case):
>>>
>>> class ResourceCombination extends WLink {
>>> -- @subsets end
>>> reference targetResource [*] container : Resource;
>>> -- @subsets end
>>> reference createActions [*] container : Resource;
>>> }
>>> class Resource extends WLinkEnd {
>>> }
>>>
>>> and now I want to express that, when I draw a "ResourceCombination"
>>> link, every action that exists on the "createActions" Resource should
>>> be created in the "targetResource" Resource (I want to do more
>>> complicated things with it, but lets start with this).
>>> In atl, such rule would be:
>>>
>>> rule ActionsToResource --My
>>> guess is that the rule name doesn't affect
>>> {
>>> from
>>> cO : MMA!Resource
>>> to
>>> out : MMB!Resource
>>> (
>>> action <- cO.action --where
>>> "action" is a set of "Action" elements )
>>> }
>>>
>>> What I don't know how to do is to associate the weaving model (.amw)
>>> with the transformation rules (.atl), in order to apply the weavings.
>>> How does the linking of the amw extensions with the rules takes place?.
>>> Thank you very much.
>>> Regards,
>>> Juan Pedro
>>>
>>>
>>>
>>> Marcos Didonet Del Fabro escribió:
>>>> Hello,
>>>>
>>>>
>>>> In aspect oriented modeling, the metamodels are combined. It would
>>>> be the creation of MMA + SecureUML metamodel based on links between
>>>> MMA and SecureUML.
>>>>
>>>> Your case seems more similar to the "Merge of geographical data" use
>>>> case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>
>>>> This is a complex case, where the generated transformation must take
>>>> two models as input and produce one model as output. You need a
>>>> special extension of AMW to support this kind of scenario. Take a
>>>> look on this use case to see if you can get some inspiration. :) Let
>>>> me know if you have any other questions.
>>>>
>>>> Regards,
>>>>
>>>> Marcos.
>>>>
>>>> Juan Pedro Silva wrote:
>>>>> Hi Marcos and everybody.
>>>>> I'm trying to use AMW for the first time, and I believe I could use
>>>>> some help from people with more knowledge of it than me.
>>>>>
>>>>> I would like to use AMW to combine models (in a sort of
>>>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding to
>>>>> Meta-Model "A" (something like a simpler version of UML), and a
>>>>> second model "IN2", that is a security model that corresponds to
>>>>> SecureUML metamodel. I wanted to combine this two models into a
>>>>> target model that corresponds to a metamodel that is the result of
>>>>> the merging of the first two (see the attached picture). This
>>>>> "combination" of the models is more than a mere merging.
>>>>>
>>>>> How could I do this?. In the use cases I saw from the website there
>>>>> is always one input model and some matching rules to generate one
>>>>> output model (sort of as in a simple ATL transformation).
>>>>> I tried using the wizard declaring two input models (IN1 and IN2)
>>>>> and the output metamodel, but when it comes to choosing the input,
>>>>> I can only choose one element from either one of the input models.
>>>>>
>>>>> I believe I'm missing the big picture here, and I surely need some
>>>>> advice to get going.
>>>>> Any help will be greatly appreciated.
>>>>> Regards,
>>>>> Juan Pedro
>>>>>
>>>>>
>>>>> ------------------------------------------------------------ ------------
>>>>>
>>>>>
Re: Model combination. [message #469548 is a reply to message #469545] Fri, 30 January 2009 07:36 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
Hi Marcos, thanks for your quick answer.
Ok on the HOT, I'll work on it.
Regarding the matching operations, I was using the extensions you
enumerated, and no others. I was following the "Metamodel comparison"
use case verbatim with my own metamodels.
The input model for the "Name Equality" matching operation was the
output of the "cartesian product" operation. Validating this model
returns no error or warnings.

I looked for the matching rule (in the "_cp.amw") model that shows up in
the error stack ("UIComboBox_EAnnotation"), and it has a right element:

<ownedElement xsi:type="ElementEqual" name="UIComboBox_EAnnotation"
similarity="0.0">
<left xsi:type="LeftElement" name="UIComboBox"
element="//@leftM/@ownedElementRef.18"/>
<right xsi:type="RightElement" name="EAnnotation"
element="//@rightM/@ownedElementRef.108"/>
</ownedElement>

I even navigated throw the "_cp.amw" file (opening it with the text
editor) and found no rule that hadn't a right element (this was not
exhaustive, though, as there are 223214 lines in that file).
Re-running the "Name Equality" operation throws the same error but in a
different rule each time.
Any ideas?, would size be an issue?. I ask this because it takes quite
some time (a couple of minutes) to open this file with the AMW editor,
for instance.
Regards,
Juan Pedro


Marcos Didonet Del Fabro escribió:
> Hello,
>
> The matching transformations, as well as the corresponding HOTs, are
> implemented based on specific extensions to the AMW core metamodel. If
> you want to use new extensions, the HOT must be extended to be able to
> support them.
>
> To execute the matching transformations of the plug-in, the following
> extensions are needed:
> - mw_base_ext
> - mmw_match (equality, cardinality, type and conformance, Cartesian
> product, link rewriting, threshold)
> - mm_propagation (SF, propagation graph)
> - mmw_compare (not equivalence)
>
> If you add new extensions, the transformations won't produce any
> additional result, since they are not aware of the existence of new
> types of links.
>
> Now, looking at your error log, it seems that you don't have any
> element associated to the "right" reference:
>
> variables = {left = left!UIComboBox}}, 'right']
>
> The transformations need to have the "left" and "right" references set
> up in the weaving model.
>
> Regards,
>
> Marcos.
>
>
> Juan Pedro Silva wrote:
>> Hi Marcos, sorry for not being clear.
>> Your answer is of great help to manually generate the
>> transformations. I'm currently generating the weaving model manually,
>> but it will take some time to finish due to the size (moderate, but
>> not small) of the metamodels. After that I'll give this a try.
>>
>> I was referring to the HOT (or "transfGen", as you call it in your
>> phd Thesis).
>> I'm having problems with the automatic generation of the
>> transformation, in various steps.
>> What I'm trying to do at this point (I postponed the combination of
>> models until I get this right) is:
>>
>> 1. An automatic Matching model (as in the "Metamodel comparison use
>> case") for my own metamodels.
>> 2. Manually tune this model with some other wlink extensions
>> (previously loading my km3 extension).
>> 3. Generate the ATL transformation (HOT) by means of the AMW context
>> menu option.
>>
>> However, I'm getting errors in step 1. I can execute the "Metamodel
>> Match -> Cartesian Product" (takes long but works), but I get errors
>> when running the "Name Equality" on the cp result (I'm attaching the
>> console output). I also get an error while trying step 3 on a partial
>> weaving model, but as the weaving model was partial and manual, I'll
>> wait until it is complete and try again.
>>
>> The question would be, are there any conditions on the metamodels in
>> order for the matching to work?, and is the available HOT general
>> enough for using it with our own weaving-metamodel extensions, or I
>> am supposed to make my own HOTs for them?.
>>
>> Thanks again, Marcos.
>> Regards,
>> Juan Pedro
>>
>>
>>
>> Marcos Didonet Del Fabro escribió:
>>>
>>> Hello,
>>>
>>> I didn't understand what you mean by "linking the rules with ATL".
>>>
>>> You can set the weaving model as input (or output) in the ATL
>>> transformation, and than use it in different ways. I depict some below:
>>>
>>> The signature of the transformation would be the following:
>>>
>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>
>>> 1) Matching the weaving link + the target actions:
>>>
>>> rule MatchLink {
>>>
>>> from
>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>> condition to verify the correct input resource )
>>>
>>> to
>>> out : MMB!Resource (
>>> action <- -- check for the target resource actions
>>> -- see the AMW model handler Wiki
>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check how
>>> the getReffered() method works)
>>> )
>>>
>>> }
>>>
>>> 2) you can create the rule similar as the one you have, and search
>>> for the linked elements.
>>>
>>> rule ActionsToResource {
>>> from
>>> cO : MMA!Resource
>>> to
>>> out : MMB!Resource
>>> (
>>> action <- cO.getOutputActions() -- The helper is
>>> created for better readability.
>>> )
>>> }
>>>
>>>
>>> helper context MMA!Resource getOutputActions() : Sequence
>>> (MMA!Action) =
>>> -- the helper should search for the ResourceCombination links and
>>> that returns the model elements based on the values of the
>>> references targetResource and createAction.
>>>
>>>
>>> Regards,
>>>
>>> Marcos.
>>>
>>>
>>>
>>> Juan Pedro Silva wrote:
>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>> I have a doubt regarding how to link the semantics of the
>>>> transformation with the definition of the weaving metamodel
>>>> extensions.
>>>>
>>>> For example, I define the following extension (I based it on the
>>>> AOM use case):
>>>>
>>>> class ResourceCombination extends WLink {
>>>> -- @subsets end
>>>> reference targetResource [*] container : Resource;
>>>> -- @subsets end
>>>> reference createActions [*] container : Resource;
>>>> }
>>>> class Resource extends WLinkEnd {
>>>> }
>>>>
>>>> and now I want to express that, when I draw a "ResourceCombination"
>>>> link, every action that exists on the "createActions" Resource
>>>> should be created in the "targetResource" Resource (I want to do
>>>> more complicated things with it, but lets start with this).
>>>> In atl, such rule would be:
>>>>
>>>> rule ActionsToResource --My
>>>> guess is that the rule name doesn't affect
>>>> {
>>>> from
>>>> cO : MMA!Resource
>>>> to
>>>> out : MMB!Resource
>>>> (
>>>> action <- cO.action --where
>>>> "action" is a set of "Action" elements )
>>>> }
>>>>
>>>> What I don't know how to do is to associate the weaving model
>>>> (.amw) with the transformation rules (.atl), in order to apply the
>>>> weavings.
>>>> How does the linking of the amw extensions with the rules takes
>>>> place?.
>>>> Thank you very much.
>>>> Regards,
>>>> Juan Pedro
>>>>
>>>>
>>>>
>>>> Marcos Didonet Del Fabro escribió:
>>>>> Hello,
>>>>>
>>>>>
>>>>> In aspect oriented modeling, the metamodels are combined. It would
>>>>> be the creation of MMA + SecureUML metamodel based on links
>>>>> between MMA and SecureUML.
>>>>>
>>>>> Your case seems more similar to the "Merge of geographical data"
>>>>> use case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>
>>>>> This is a complex case, where the generated transformation must
>>>>> take two models as input and produce one model as output. You need
>>>>> a special extension of AMW to support this kind of scenario. Take
>>>>> a look on this use case to see if you can get some inspiration. :)
>>>>> Let me know if you have any other questions.
>>>>>
>>>>> Regards,
>>>>>
>>>>> Marcos.
>>>>>
>>>>> Juan Pedro Silva wrote:
>>>>>> Hi Marcos and everybody.
>>>>>> I'm trying to use AMW for the first time, and I believe I could
>>>>>> use some help from people with more knowledge of it than me.
>>>>>>
>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding to
>>>>>> Meta-Model "A" (something like a simpler version of UML), and a
>>>>>> second model "IN2", that is a security model that corresponds to
>>>>>> SecureUML metamodel. I wanted to combine this two models into a
>>>>>> target model that corresponds to a metamodel that is the result
>>>>>> of the merging of the first two (see the attached picture). This
>>>>>> "combination" of the models is more than a mere merging.
>>>>>>
>>>>>> How could I do this?. In the use cases I saw from the website
>>>>>> there is always one input model and some matching rules to
>>>>>> generate one output model (sort of as in a simple ATL
>>>>>> transformation).
>>>>>> I tried using the wizard declaring two input models (IN1 and IN2)
>>>>>> and the output metamodel, but when it comes to choosing the
>>>>>> input, I can only choose one element from either one of the input
>>>>>> models.
>>>>>>
>>>>>> I believe I'm missing the big picture here, and I surely need
>>>>>> some advice to get going.
>>>>>> Any help will be greatly appreciated.
>>>>>> Regards,
>>>>>> Juan Pedro
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------ ------------
>>>>>>
>>>>>>
Re: Model combination. [message #469551 is a reply to message #469548] Fri, 30 January 2009 07:53 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
Hi,

The problem is that it didn't find the right element (it returned a
"null" in the getElementRef method. However, I cannot say why this is
happening. Maybe there is a path problem or something related.

Can you copy the value of the "rightM" and "leftM" elements, and an
excerpt of the .prop.amw.file with the file paths?

The "rightM" element looks like the following:
<rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
ref="/<metamodelpath>.ecore">



Marcos.

Juan Pedro Silva wrote:
> Hi Marcos, thanks for your quick answer.
> Ok on the HOT, I'll work on it.
> Regarding the matching operations, I was using the extensions you
> enumerated, and no others. I was following the "Metamodel comparison"
> use case verbatim with my own metamodels.
> The input model for the "Name Equality" matching operation was the
> output of the "cartesian product" operation. Validating this model
> returns no error or warnings.
>
> I looked for the matching rule (in the "_cp.amw") model that shows up in
> the error stack ("UIComboBox_EAnnotation"), and it has a right element:
>
> <ownedElement xsi:type="ElementEqual" name="UIComboBox_EAnnotation"
> similarity="0.0">
> <left xsi:type="LeftElement" name="UIComboBox"
> element="//@leftM/@ownedElementRef.18"/>
> <right xsi:type="RightElement" name="EAnnotation"
> element="//@rightM/@ownedElementRef.108"/>
> </ownedElement>
>
> I even navigated throw the "_cp.amw" file (opening it with the text
> editor) and found no rule that hadn't a right element (this was not
> exhaustive, though, as there are 223214 lines in that file).
> Re-running the "Name Equality" operation throws the same error but in a
> different rule each time.
> Any ideas?, would size be an issue?. I ask this because it takes quite
> some time (a couple of minutes) to open this file with the AMW editor,
> for instance.
> Regards,
> Juan Pedro
>
>
> Marcos Didonet Del Fabro escribió:
>> Hello,
>>
>> The matching transformations, as well as the corresponding HOTs, are
>> implemented based on specific extensions to the AMW core metamodel. If
>> you want to use new extensions, the HOT must be extended to be able to
>> support them.
>>
>> To execute the matching transformations of the plug-in, the following
>> extensions are needed:
>> - mw_base_ext
>> - mmw_match (equality, cardinality, type and conformance, Cartesian
>> product, link rewriting, threshold)
>> - mm_propagation (SF, propagation graph)
>> - mmw_compare (not equivalence)
>>
>> If you add new extensions, the transformations won't produce any
>> additional result, since they are not aware of the existence of new
>> types of links.
>>
>> Now, looking at your error log, it seems that you don't have any
>> element associated to the "right" reference:
>>
>> variables = {left = left!UIComboBox}}, 'right']
>>
>> The transformations need to have the "left" and "right" references set
>> up in the weaving model.
>>
>> Regards,
>>
>> Marcos.
>>
>>
>> Juan Pedro Silva wrote:
>>> Hi Marcos, sorry for not being clear.
>>> Your answer is of great help to manually generate the
>>> transformations. I'm currently generating the weaving model manually,
>>> but it will take some time to finish due to the size (moderate, but
>>> not small) of the metamodels. After that I'll give this a try.
>>>
>>> I was referring to the HOT (or "transfGen", as you call it in your
>>> phd Thesis).
>>> I'm having problems with the automatic generation of the
>>> transformation, in various steps.
>>> What I'm trying to do at this point (I postponed the combination of
>>> models until I get this right) is:
>>>
>>> 1. An automatic Matching model (as in the "Metamodel comparison use
>>> case") for my own metamodels.
>>> 2. Manually tune this model with some other wlink extensions
>>> (previously loading my km3 extension).
>>> 3. Generate the ATL transformation (HOT) by means of the AMW context
>>> menu option.
>>>
>>> However, I'm getting errors in step 1. I can execute the "Metamodel
>>> Match -> Cartesian Product" (takes long but works), but I get errors
>>> when running the "Name Equality" on the cp result (I'm attaching the
>>> console output). I also get an error while trying step 3 on a partial
>>> weaving model, but as the weaving model was partial and manual, I'll
>>> wait until it is complete and try again.
>>>
>>> The question would be, are there any conditions on the metamodels in
>>> order for the matching to work?, and is the available HOT general
>>> enough for using it with our own weaving-metamodel extensions, or I
>>> am supposed to make my own HOTs for them?.
>>>
>>> Thanks again, Marcos.
>>> Regards,
>>> Juan Pedro
>>>
>>>
>>>
>>> Marcos Didonet Del Fabro escribió:
>>>>
>>>> Hello,
>>>>
>>>> I didn't understand what you mean by "linking the rules with ATL".
>>>>
>>>> You can set the weaving model as input (or output) in the ATL
>>>> transformation, and than use it in different ways. I depict some below:
>>>>
>>>> The signature of the transformation would be the following:
>>>>
>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>
>>>> 1) Matching the weaving link + the target actions:
>>>>
>>>> rule MatchLink {
>>>>
>>>> from
>>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>>> condition to verify the correct input resource )
>>>>
>>>> to
>>>> out : MMB!Resource (
>>>> action <- -- check for the target resource actions
>>>> -- see the AMW model handler Wiki
>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check how
>>>> the getReffered() method works)
>>>> )
>>>>
>>>> }
>>>>
>>>> 2) you can create the rule similar as the one you have, and search
>>>> for the linked elements.
>>>>
>>>> rule ActionsToResource {
>>>> from
>>>> cO : MMA!Resource
>>>> to
>>>> out : MMB!Resource
>>>> (
>>>> action <- cO.getOutputActions() -- The helper is
>>>> created for better readability.
>>>> )
>>>> }
>>>>
>>>>
>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>> (MMA!Action) =
>>>> -- the helper should search for the ResourceCombination links and
>>>> that returns the model elements based on the values of the
>>>> references targetResource and createAction.
>>>>
>>>>
>>>> Regards,
>>>>
>>>> Marcos.
>>>>
>>>>
>>>>
>>>> Juan Pedro Silva wrote:
>>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>>> I have a doubt regarding how to link the semantics of the
>>>>> transformation with the definition of the weaving metamodel
>>>>> extensions.
>>>>>
>>>>> For example, I define the following extension (I based it on the
>>>>> AOM use case):
>>>>>
>>>>> class ResourceCombination extends WLink {
>>>>> -- @subsets end
>>>>> reference targetResource [*] container : Resource;
>>>>> -- @subsets end
>>>>> reference createActions [*] container : Resource;
>>>>> }
>>>>> class Resource extends WLinkEnd {
>>>>> }
>>>>>
>>>>> and now I want to express that, when I draw a "ResourceCombination"
>>>>> link, every action that exists on the "createActions" Resource
>>>>> should be created in the "targetResource" Resource (I want to do
>>>>> more complicated things with it, but lets start with this).
>>>>> In atl, such rule would be:
>>>>>
>>>>> rule ActionsToResource --My
>>>>> guess is that the rule name doesn't affect
>>>>> {
>>>>> from
>>>>> cO : MMA!Resource
>>>>> to
>>>>> out : MMB!Resource
>>>>> (
>>>>> action <- cO.action --where
>>>>> "action" is a set of "Action" elements )
>>>>> }
>>>>>
>>>>> What I don't know how to do is to associate the weaving model
>>>>> (.amw) with the transformation rules (.atl), in order to apply the
>>>>> weavings.
>>>>> How does the linking of the amw extensions with the rules takes
>>>>> place?.
>>>>> Thank you very much.
>>>>> Regards,
>>>>> Juan Pedro
>>>>>
>>>>>
>>>>>
>>>>> Marcos Didonet Del Fabro escribió:
>>>>>> Hello,
>>>>>>
>>>>>>
>>>>>> In aspect oriented modeling, the metamodels are combined. It would
>>>>>> be the creation of MMA + SecureUML metamodel based on links
>>>>>> between MMA and SecureUML.
>>>>>>
>>>>>> Your case seems more similar to the "Merge of geographical data"
>>>>>> use case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>
>>>>>> This is a complex case, where the generated transformation must
>>>>>> take two models as input and produce one model as output. You need
>>>>>> a special extension of AMW to support this kind of scenario. Take
>>>>>> a look on this use case to see if you can get some inspiration. :)
>>>>>> Let me know if you have any other questions.
>>>>>>
>>>>>> Regards,
>>>>>>
>>>>>> Marcos.
>>>>>>
>>>>>> Juan Pedro Silva wrote:
>>>>>>> Hi Marcos and everybody.
>>>>>>> I'm trying to use AMW for the first time, and I believe I could
>>>>>>> use some help from people with more knowledge of it than me.
>>>>>>>
>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding to
>>>>>>> Meta-Model "A" (something like a simpler version of UML), and a
>>>>>>> second model "IN2", that is a security model that corresponds to
>>>>>>> SecureUML metamodel. I wanted to combine this two models into a
>>>>>>> target model that corresponds to a metamodel that is the result
>>>>>>> of the merging of the first two (see the attached picture). This
>>>>>>> "combination" of the models is more than a mere merging.
>>>>>>>
>>>>>>> How could I do this?. In the use cases I saw from the website
>>>>>>> there is always one input model and some matching rules to
>>>>>>> generate one output model (sort of as in a simple ATL
>>>>>>> transformation).
>>>>>>> I tried using the wizard declaring two input models (IN1 and IN2)
>>>>>>> and the output metamodel, but when it comes to choosing the
>>>>>>> input, I can only choose one element from either one of the input
>>>>>>> models.
>>>>>>>
>>>>>>> I believe I'm missing the big picture here, and I surely need
>>>>>>> some advice to get going.
>>>>>>> Any help will be greatly appreciated.
>>>>>>> Regards,
>>>>>>> Juan Pedro
>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>
>>>>>>>
Re: Model combination. [message #469553 is a reply to message #469551] Fri, 30 January 2009 08:14 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
Marcos:

<leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">

<rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">

And the .prop.amw file:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<weaver>
<weaving>
<relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
<panel>TransformationWeavingPanelExtension</panel>
<wmodel>MatchModel</wmodel>
</weaving>
<metamodels>
<plugin>
<relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
<relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
<relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
<relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
</plugin>
<local/>
<complete/>
</metamodels>
<woven id="0">
<model-relative-path>null</model-relative-path>
<metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
<reference>leftM</reference>
<title>leftM</title>
<panel>DefaultWovenPanelExtension</panel>
<wmodelref>ModelRef</wmodelref>
</woven>
<woven id="1">
<model-relative-path>null</model-relative-path>
<metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
<reference>rightM</reference>
<title>rightM</title>
<panel>DefaultWovenPanelExtension</panel>
<wmodelref>ModelRef</wmodelref>
</woven>
</weaver>

I load the metamodels in the wizard from other project, do you think
this could create problems?.
I could try copying them into this one and see if that helps.
Regards, and thanks for your help.



Marcos Didonet Del Fabro escribió:
> Hi,
>
> The problem is that it didn't find the right element (it returned a
> "null" in the getElementRef method. However, I cannot say why this is
> happening. Maybe there is a path problem or something related.
>
> Can you copy the value of the "rightM" and "leftM" elements, and an
> excerpt of the .prop.amw.file with the file paths?
>
> The "rightM" element looks like the following:
> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
> ref="/<metamodelpath>.ecore">
>
>
>
> Marcos.
>
> Juan Pedro Silva wrote:
>> Hi Marcos, thanks for your quick answer.
>> Ok on the HOT, I'll work on it.
>> Regarding the matching operations, I was using the extensions you
>> enumerated, and no others. I was following the "Metamodel comparison"
>> use case verbatim with my own metamodels.
>> The input model for the "Name Equality" matching operation was the
>> output of the "cartesian product" operation. Validating this model
>> returns no error or warnings.
>>
>> I looked for the matching rule (in the "_cp.amw") model that shows up
>> in the error stack ("UIComboBox_EAnnotation"), and it has a right
>> element:
>>
>> <ownedElement xsi:type="ElementEqual" name="UIComboBox_EAnnotation"
>> similarity="0.0">
>> <left xsi:type="LeftElement" name="UIComboBox"
>> element="//@leftM/@ownedElementRef.18"/>
>> <right xsi:type="RightElement" name="EAnnotation"
>> element="//@rightM/@ownedElementRef.108"/>
>> </ownedElement>
>>
>> I even navigated throw the "_cp.amw" file (opening it with the text
>> editor) and found no rule that hadn't a right element (this was not
>> exhaustive, though, as there are 223214 lines in that file).
>> Re-running the "Name Equality" operation throws the same error but in
>> a different rule each time.
>> Any ideas?, would size be an issue?. I ask this because it takes
>> quite some time (a couple of minutes) to open this file with the AMW
>> editor, for instance.
>> Regards,
>> Juan Pedro
>>
>>
>> Marcos Didonet Del Fabro escribió:
>>> Hello,
>>>
>>> The matching transformations, as well as the corresponding HOTs, are
>>> implemented based on specific extensions to the AMW core metamodel.
>>> If you want to use new extensions, the HOT must be extended to be
>>> able to support them.
>>>
>>> To execute the matching transformations of the plug-in, the
>>> following extensions are needed:
>>> - mw_base_ext
>>> - mmw_match (equality, cardinality, type and conformance, Cartesian
>>> product, link rewriting, threshold)
>>> - mm_propagation (SF, propagation graph)
>>> - mmw_compare (not equivalence)
>>>
>>> If you add new extensions, the transformations won't produce any
>>> additional result, since they are not aware of the existence of new
>>> types of links.
>>>
>>> Now, looking at your error log, it seems that you don't have any
>>> element associated to the "right" reference:
>>>
>>> variables = {left = left!UIComboBox}}, 'right']
>>>
>>> The transformations need to have the "left" and "right" references
>>> set up in the weaving model.
>>>
>>> Regards,
>>>
>>> Marcos.
>>>
>>>
>>> Juan Pedro Silva wrote:
>>>> Hi Marcos, sorry for not being clear.
>>>> Your answer is of great help to manually generate the
>>>> transformations. I'm currently generating the weaving model
>>>> manually, but it will take some time to finish due to the size
>>>> (moderate, but not small) of the metamodels. After that I'll give
>>>> this a try.
>>>>
>>>> I was referring to the HOT (or "transfGen", as you call it in your
>>>> phd Thesis).
>>>> I'm having problems with the automatic generation of the
>>>> transformation, in various steps.
>>>> What I'm trying to do at this point (I postponed the combination of
>>>> models until I get this right) is:
>>>>
>>>> 1. An automatic Matching model (as in the "Metamodel comparison
>>>> use
>>>> case") for my own metamodels.
>>>> 2. Manually tune this model with some other wlink extensions
>>>> (previously loading my km3 extension).
>>>> 3. Generate the ATL transformation (HOT) by means of the AMW
>>>> context
>>>> menu option.
>>>>
>>>> However, I'm getting errors in step 1. I can execute the "Metamodel
>>>> Match -> Cartesian Product" (takes long but works), but I get
>>>> errors when running the "Name Equality" on the cp result (I'm
>>>> attaching the console output). I also get an error while trying
>>>> step 3 on a partial weaving model, but as the weaving model was
>>>> partial and manual, I'll wait until it is complete and try again.
>>>>
>>>> The question would be, are there any conditions on the metamodels
>>>> in order for the matching to work?, and is the available HOT
>>>> general enough for using it with our own weaving-metamodel
>>>> extensions, or I am supposed to make my own HOTs for them?.
>>>>
>>>> Thanks again, Marcos.
>>>> Regards,
>>>> Juan Pedro
>>>>
>>>>
>>>>
>>>> Marcos Didonet Del Fabro escribió:
>>>>>
>>>>> Hello,
>>>>>
>>>>> I didn't understand what you mean by "linking the rules with ATL".
>>>>>
>>>>> You can set the weaving model as input (or output) in the ATL
>>>>> transformation, and than use it in different ways. I depict some
>>>>> below:
>>>>>
>>>>> The signature of the transformation would be the following:
>>>>>
>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>
>>>>> 1) Matching the weaving link + the target actions:
>>>>>
>>>>> rule MatchLink {
>>>>>
>>>>> from
>>>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>>>> condition to verify the correct input resource )
>>>>>
>>>>> to
>>>>> out : MMB!Resource (
>>>>> action <- -- check for the target resource actions
>>>>> -- see the AMW model handler Wiki
>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check how
>>>>> the getReffered() method works)
>>>>> )
>>>>>
>>>>> }
>>>>>
>>>>> 2) you can create the rule similar as the one you have, and search
>>>>> for the linked elements.
>>>>>
>>>>> rule ActionsToResource {
>>>>> from
>>>>> cO : MMA!Resource
>>>>> to
>>>>> out : MMB!Resource
>>>>> (
>>>>> action <- cO.getOutputActions() -- The helper is
>>>>> created for better readability.
>>>>> )
>>>>> }
>>>>>
>>>>>
>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>> (MMA!Action) =
>>>>> -- the helper should search for the ResourceCombination links
>>>>> and that returns the model elements based on the values of the
>>>>> references targetResource and createAction.
>>>>>
>>>>>
>>>>> Regards,
>>>>>
>>>>> Marcos.
>>>>>
>>>>>
>>>>>
>>>>> Juan Pedro Silva wrote:
>>>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>> transformation with the definition of the weaving metamodel
>>>>>> extensions.
>>>>>>
>>>>>> For example, I define the following extension (I based it on the
>>>>>> AOM use case):
>>>>>>
>>>>>> class ResourceCombination extends WLink {
>>>>>> -- @subsets end
>>>>>> reference targetResource [*] container : Resource;
>>>>>> -- @subsets end
>>>>>> reference createActions [*] container : Resource;
>>>>>> }
>>>>>> class Resource extends WLinkEnd {
>>>>>> }
>>>>>>
>>>>>> and now I want to express that, when I draw a
>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>> "createActions" Resource should be created in the
>>>>>> "targetResource" Resource (I want to do more complicated things
>>>>>> with it, but lets start with this).
>>>>>> In atl, such rule would be:
>>>>>>
>>>>>> rule ActionsToResource --My
>>>>>> guess is that the rule name doesn't affect
>>>>>> {
>>>>>> from
>>>>>> cO : MMA!Resource
>>>>>> to
>>>>>> out : MMB!Resource
>>>>>> (
>>>>>> action <- cO.action
>>>>>> --where "action" is a set of "Action"
>>>>>> elements )
>>>>>> }
>>>>>>
>>>>>> What I don't know how to do is to associate the weaving model
>>>>>> (.amw) with the transformation rules (.atl), in order to apply
>>>>>> the weavings.
>>>>>> How does the linking of the amw extensions with the rules takes
>>>>>> place?.
>>>>>> Thank you very much.
>>>>>> Regards,
>>>>>> Juan Pedro
>>>>>>
>>>>>>
>>>>>>
>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>> Hello,
>>>>>>>
>>>>>>>
>>>>>>> In aspect oriented modeling, the metamodels are combined. It
>>>>>>> would be the creation of MMA + SecureUML metamodel based on
>>>>>>> links between MMA and SecureUML.
>>>>>>>
>>>>>>> Your case seems more similar to the "Merge of geographical data"
>>>>>>> use case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>
>>>>>>> This is a complex case, where the generated transformation must
>>>>>>> take two models as input and produce one model as output. You
>>>>>>> need a special extension of AMW to support this kind of
>>>>>>> scenario. Take a look on this use case to see if you can get
>>>>>>> some inspiration. :) Let me know if you have any other questions.
>>>>>>>
>>>>>>> Regards,
>>>>>>>
>>>>>>> Marcos.
>>>>>>>
>>>>>>> Juan Pedro Silva wrote:
>>>>>>>> Hi Marcos and everybody.
>>>>>>>> I'm trying to use AMW for the first time, and I believe I could
>>>>>>>> use some help from people with more knowledge of it than me.
>>>>>>>>
>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding
>>>>>>>> to Meta-Model "A" (something like a simpler version of UML),
>>>>>>>> and a second model "IN2", that is a security model that
>>>>>>>> corresponds to SecureUML metamodel. I wanted to combine this
>>>>>>>> two models into a target model that corresponds to a metamodel
>>>>>>>> that is the result of the merging of the first two (see the
>>>>>>>> attached picture). This "combination" of the models is more
>>>>>>>> than a mere merging.
>>>>>>>>
>>>>>>>> How could I do this?. In the use cases I saw from the website
>>>>>>>> there is always one input model and some matching rules to
>>>>>>>> generate one output model (sort of as in a simple ATL
>>>>>>>> transformation).
>>>>>>>> I tried using the wizard declaring two input models (IN1 and
>>>>>>>> IN2) and the output metamodel, but when it comes to choosing
>>>>>>>> the input, I can only choose one element from either one of the
>>>>>>>> input models.
>>>>>>>>
>>>>>>>> I believe I'm missing the big picture here, and I surely need
>>>>>>>> some advice to get going.
>>>>>>>> Any help will be greatly appreciated.
>>>>>>>> Regards,
>>>>>>>> Juan Pedro
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>
>>>>>>>>
Re: Model combination. [message #469555 is a reply to message #469553] Fri, 30 January 2009 08:44 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
Making a new model weaverwith the metamodels in the root folder of the
same project has the same results as in the previous one, regretfully.

Juan Pedro Silva escribió:
> Marcos:
>
> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>
> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>
>
> And the .prop.amw file:
>
> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
> <weaver>
> <weaving>
> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
> <panel>TransformationWeavingPanelExtension</panel>
> <wmodel>MatchModel</wmodel>
> </weaving>
> <metamodels>
> <plugin>
> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>
> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>
> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>
> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>
> </plugin>
> <local/>
> <complete/>
> </metamodels>
> <woven id="0">
> <model-relative-path>null</model-relative-path>
> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>
> <reference>leftM</reference>
> <title>leftM</title>
> <panel>DefaultWovenPanelExtension</panel>
> <wmodelref>ModelRef</wmodelref>
> </woven>
> <woven id="1">
> <model-relative-path>null</model-relative-path>
> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>
> <reference>rightM</reference>
> <title>rightM</title>
> <panel>DefaultWovenPanelExtension</panel>
> <wmodelref>ModelRef</wmodelref>
> </woven>
> </weaver>
>
> I load the metamodels in the wizard from other project, do you think
> this could create problems?.
> I could try copying them into this one and see if that helps.
> Regards, and thanks for your help.
>
>
>
> Marcos Didonet Del Fabro escribió:
>> Hi,
>>
>> The problem is that it didn't find the right element (it returned a
>> "null" in the getElementRef method. However, I cannot say why this is
>> happening. Maybe there is a path problem or something related.
>>
>> Can you copy the value of the "rightM" and "leftM" elements, and an
>> excerpt of the .prop.amw.file with the file paths?
>>
>> The "rightM" element looks like the following:
>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>> ref="/<metamodelpath>.ecore">
>>
>>
>>
>> Marcos.
>>
>> Juan Pedro Silva wrote:
>>> Hi Marcos, thanks for your quick answer.
>>> Ok on the HOT, I'll work on it.
>>> Regarding the matching operations, I was using the extensions you
>>> enumerated, and no others. I was following the "Metamodel
>>> comparison" use case verbatim with my own metamodels.
>>> The input model for the "Name Equality" matching operation was the
>>> output of the "cartesian product" operation. Validating this model
>>> returns no error or warnings.
>>>
>>> I looked for the matching rule (in the "_cp.amw") model that shows
>>> up in the error stack ("UIComboBox_EAnnotation"), and it has a right
>>> element:
>>>
>>> <ownedElement xsi:type="ElementEqual" name="UIComboBox_EAnnotation"
>>> similarity="0.0">
>>> <left xsi:type="LeftElement" name="UIComboBox"
>>> element="//@leftM/@ownedElementRef.18"/>
>>> <right xsi:type="RightElement" name="EAnnotation"
>>> element="//@rightM/@ownedElementRef.108"/>
>>> </ownedElement>
>>>
>>> I even navigated throw the "_cp.amw" file (opening it with the text
>>> editor) and found no rule that hadn't a right element (this was not
>>> exhaustive, though, as there are 223214 lines in that file).
>>> Re-running the "Name Equality" operation throws the same error but
>>> in a different rule each time.
>>> Any ideas?, would size be an issue?. I ask this because it takes
>>> quite some time (a couple of minutes) to open this file with the AMW
>>> editor, for instance.
>>> Regards,
>>> Juan Pedro
>>>
>>>
>>> Marcos Didonet Del Fabro escribió:
>>>> Hello,
>>>>
>>>> The matching transformations, as well as the corresponding HOTs,
>>>> are implemented based on specific extensions to the AMW core
>>>> metamodel. If you want to use new extensions, the HOT must be
>>>> extended to be able to support them.
>>>>
>>>> To execute the matching transformations of the plug-in, the
>>>> following extensions are needed:
>>>> - mw_base_ext
>>>> - mmw_match (equality, cardinality, type and conformance, Cartesian
>>>> product, link rewriting, threshold)
>>>> - mm_propagation (SF, propagation graph)
>>>> - mmw_compare (not equivalence)
>>>>
>>>> If you add new extensions, the transformations won't produce any
>>>> additional result, since they are not aware of the existence of new
>>>> types of links.
>>>>
>>>> Now, looking at your error log, it seems that you don't have any
>>>> element associated to the "right" reference:
>>>>
>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>
>>>> The transformations need to have the "left" and "right" references
>>>> set up in the weaving model.
>>>>
>>>> Regards,
>>>>
>>>> Marcos.
>>>>
>>>>
>>>> Juan Pedro Silva wrote:
>>>>> Hi Marcos, sorry for not being clear.
>>>>> Your answer is of great help to manually generate the
>>>>> transformations. I'm currently generating the weaving model
>>>>> manually, but it will take some time to finish due to the size
>>>>> (moderate, but not small) of the metamodels. After that I'll give
>>>>> this a try.
>>>>>
>>>>> I was referring to the HOT (or "transfGen", as you call it in your
>>>>> phd Thesis).
>>>>> I'm having problems with the automatic generation of the
>>>>> transformation, in various steps.
>>>>> What I'm trying to do at this point (I postponed the combination
>>>>> of models until I get this right) is:
>>>>>
>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>> comparison use
>>>>> case") for my own metamodels.
>>>>> 2. Manually tune this model with some other wlink extensions
>>>>> (previously loading my km3 extension).
>>>>> 3. Generate the ATL transformation (HOT) by means of the AMW
>>>>> context
>>>>> menu option.
>>>>>
>>>>> However, I'm getting errors in step 1. I can execute the
>>>>> "Metamodel Match -> Cartesian Product" (takes long but works), but
>>>>> I get errors when running the "Name Equality" on the cp result
>>>>> (I'm attaching the console output). I also get an error while
>>>>> trying step 3 on a partial weaving model, but as the weaving model
>>>>> was partial and manual, I'll wait until it is complete and try again.
>>>>>
>>>>> The question would be, are there any conditions on the metamodels
>>>>> in order for the matching to work?, and is the available HOT
>>>>> general enough for using it with our own weaving-metamodel
>>>>> extensions, or I am supposed to make my own HOTs for them?.
>>>>>
>>>>> Thanks again, Marcos.
>>>>> Regards,
>>>>> Juan Pedro
>>>>>
>>>>>
>>>>>
>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>
>>>>>> Hello,
>>>>>>
>>>>>> I didn't understand what you mean by "linking the rules with ATL".
>>>>>>
>>>>>> You can set the weaving model as input (or output) in the ATL
>>>>>> transformation, and than use it in different ways. I depict some
>>>>>> below:
>>>>>>
>>>>>> The signature of the transformation would be the following:
>>>>>>
>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>
>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>
>>>>>> rule MatchLink {
>>>>>>
>>>>>> from
>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>>>>> condition to verify the correct input resource )
>>>>>>
>>>>>> to
>>>>>> out : MMB!Resource (
>>>>>> action <- -- check for the target resource actions
>>>>>> -- see the AMW model handler Wiki
>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check
>>>>>> how the getReffered() method works)
>>>>>> )
>>>>>>
>>>>>> }
>>>>>>
>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>> search for the linked elements.
>>>>>>
>>>>>> rule ActionsToResource {
>>>>>> from
>>>>>> cO : MMA!Resource
>>>>>> to
>>>>>> out : MMB!Resource
>>>>>> (
>>>>>> action <- cO.getOutputActions() -- The helper is
>>>>>> created for better readability.
>>>>>> )
>>>>>> }
>>>>>>
>>>>>>
>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>> (MMA!Action) =
>>>>>> -- the helper should search for the ResourceCombination links
>>>>>> and that returns the model elements based on the values of the
>>>>>> references targetResource and createAction.
>>>>>>
>>>>>>
>>>>>> Regards,
>>>>>>
>>>>>> Marcos.
>>>>>>
>>>>>>
>>>>>>
>>>>>> Juan Pedro Silva wrote:
>>>>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>> transformation with the definition of the weaving metamodel
>>>>>>> extensions.
>>>>>>>
>>>>>>> For example, I define the following extension (I based it on the
>>>>>>> AOM use case):
>>>>>>>
>>>>>>> class ResourceCombination extends WLink {
>>>>>>> -- @subsets end
>>>>>>> reference targetResource [*] container : Resource;
>>>>>>> -- @subsets end
>>>>>>> reference createActions [*] container : Resource;
>>>>>>> }
>>>>>>> class Resource extends WLinkEnd {
>>>>>>> }
>>>>>>>
>>>>>>> and now I want to express that, when I draw a
>>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>>> "createActions" Resource should be created in the
>>>>>>> "targetResource" Resource (I want to do more complicated things
>>>>>>> with it, but lets start with this).
>>>>>>> In atl, such rule would be:
>>>>>>>
>>>>>>> rule ActionsToResource --My
>>>>>>> guess is that the rule name doesn't affect
>>>>>>> {
>>>>>>> from
>>>>>>> cO : MMA!Resource
>>>>>>> to
>>>>>>> out : MMB!Resource
>>>>>>> (
>>>>>>> action <- cO.action
>>>>>>> --where "action" is a set of "Action"
>>>>>>> elements )
>>>>>>> }
>>>>>>>
>>>>>>> What I don't know how to do is to associate the weaving model
>>>>>>> (.amw) with the transformation rules (.atl), in order to apply
>>>>>>> the weavings.
>>>>>>> How does the linking of the amw extensions with the rules takes
>>>>>>> place?.
>>>>>>> Thank you very much.
>>>>>>> Regards,
>>>>>>> Juan Pedro
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>> Hello,
>>>>>>>>
>>>>>>>>
>>>>>>>> In aspect oriented modeling, the metamodels are combined. It
>>>>>>>> would be the creation of MMA + SecureUML metamodel based on
>>>>>>>> links between MMA and SecureUML.
>>>>>>>>
>>>>>>>> Your case seems more similar to the "Merge of geographical
>>>>>>>> data" use case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>
>>>>>>>> This is a complex case, where the generated transformation must
>>>>>>>> take two models as input and produce one model as output. You
>>>>>>>> need a special extension of AMW to support this kind of
>>>>>>>> scenario. Take a look on this use case to see if you can get
>>>>>>>> some inspiration. :) Let me know if you have any other questions.
>>>>>>>>
>>>>>>>> Regards,
>>>>>>>>
>>>>>>>> Marcos.
>>>>>>>>
>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>> I'm trying to use AMW for the first time, and I believe I
>>>>>>>>> could use some help from people with more knowledge of it than
>>>>>>>>> me.
>>>>>>>>>
>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding
>>>>>>>>> to Meta-Model "A" (something like a simpler version of UML),
>>>>>>>>> and a second model "IN2", that is a security model that
>>>>>>>>> corresponds to SecureUML metamodel. I wanted to combine this
>>>>>>>>> two models into a target model that corresponds to a metamodel
>>>>>>>>> that is the result of the merging of the first two (see the
>>>>>>>>> attached picture). This "combination" of the models is more
>>>>>>>>> than a mere merging.
>>>>>>>>>
>>>>>>>>> How could I do this?. In the use cases I saw from the website
>>>>>>>>> there is always one input model and some matching rules to
>>>>>>>>> generate one output model (sort of as in a simple ATL
>>>>>>>>> transformation).
>>>>>>>>> I tried using the wizard declaring two input models (IN1 and
>>>>>>>>> IN2) and the output metamodel, but when it comes to choosing
>>>>>>>>> the input, I can only choose one element from either one of
>>>>>>>>> the input models.
>>>>>>>>>
>>>>>>>>> I believe I'm missing the big picture here, and I surely need
>>>>>>>>> some advice to get going.
>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>> Regards,
>>>>>>>>> Juan Pedro
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>
>>>>>>>>>
Re: Model combination. [message #469557 is a reply to message #469555] Fri, 30 January 2009 09:54 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
It seems something related with the EAnnotation element. Can you explain
what is it about?

Marcos.

Juan Pedro Silva wrote:
> Making a new model weaverwith the metamodels in the root folder of the
> same project has the same results as in the previous one, regretfully.
>
> Juan Pedro Silva escribió:
>> Marcos:
>>
>> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
>> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>>
>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>>
>>
>> And the .prop.amw file:
>>
>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>> <weaver>
>> <weaving>
>> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
>> <panel>TransformationWeavingPanelExtension</panel>
>> <wmodel>MatchModel</wmodel>
>> </weaving>
>> <metamodels>
>> <plugin>
>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>>
>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>>
>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>>
>> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>>
>> </plugin>
>> <local/>
>> <complete/>
>> </metamodels>
>> <woven id="0">
>> <model-relative-path>null</model-relative-path>
>> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>>
>> <reference>leftM</reference>
>> <title>leftM</title>
>> <panel>DefaultWovenPanelExtension</panel>
>> <wmodelref>ModelRef</wmodelref>
>> </woven>
>> <woven id="1">
>> <model-relative-path>null</model-relative-path>
>> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>>
>> <reference>rightM</reference>
>> <title>rightM</title>
>> <panel>DefaultWovenPanelExtension</panel>
>> <wmodelref>ModelRef</wmodelref>
>> </woven>
>> </weaver>
>>
>> I load the metamodels in the wizard from other project, do you think
>> this could create problems?.
>> I could try copying them into this one and see if that helps.
>> Regards, and thanks for your help.
>>
>>
>>
>> Marcos Didonet Del Fabro escribió:
>>> Hi,
>>>
>>> The problem is that it didn't find the right element (it returned a
>>> "null" in the getElementRef method. However, I cannot say why this is
>>> happening. Maybe there is a path problem or something related.
>>>
>>> Can you copy the value of the "rightM" and "leftM" elements, and an
>>> excerpt of the .prop.amw.file with the file paths?
>>>
>>> The "rightM" element looks like the following:
>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>> ref="/<metamodelpath>.ecore">
>>>
>>>
>>>
>>> Marcos.
>>>
>>> Juan Pedro Silva wrote:
>>>> Hi Marcos, thanks for your quick answer.
>>>> Ok on the HOT, I'll work on it.
>>>> Regarding the matching operations, I was using the extensions you
>>>> enumerated, and no others. I was following the "Metamodel
>>>> comparison" use case verbatim with my own metamodels.
>>>> The input model for the "Name Equality" matching operation was the
>>>> output of the "cartesian product" operation. Validating this model
>>>> returns no error or warnings.
>>>>
>>>> I looked for the matching rule (in the "_cp.amw") model that shows
>>>> up in the error stack ("UIComboBox_EAnnotation"), and it has a right
>>>> element:
>>>>
>>>> <ownedElement xsi:type="ElementEqual" name="UIComboBox_EAnnotation"
>>>> similarity="0.0">
>>>> <left xsi:type="LeftElement" name="UIComboBox"
>>>> element="//@leftM/@ownedElementRef.18"/>
>>>> <right xsi:type="RightElement" name="EAnnotation"
>>>> element="//@rightM/@ownedElementRef.108"/>
>>>> </ownedElement>
>>>>
>>>> I even navigated throw the "_cp.amw" file (opening it with the text
>>>> editor) and found no rule that hadn't a right element (this was not
>>>> exhaustive, though, as there are 223214 lines in that file).
>>>> Re-running the "Name Equality" operation throws the same error but
>>>> in a different rule each time.
>>>> Any ideas?, would size be an issue?. I ask this because it takes
>>>> quite some time (a couple of minutes) to open this file with the AMW
>>>> editor, for instance.
>>>> Regards,
>>>> Juan Pedro
>>>>
>>>>
>>>> Marcos Didonet Del Fabro escribió:
>>>>> Hello,
>>>>>
>>>>> The matching transformations, as well as the corresponding HOTs,
>>>>> are implemented based on specific extensions to the AMW core
>>>>> metamodel. If you want to use new extensions, the HOT must be
>>>>> extended to be able to support them.
>>>>>
>>>>> To execute the matching transformations of the plug-in, the
>>>>> following extensions are needed:
>>>>> - mw_base_ext
>>>>> - mmw_match (equality, cardinality, type and conformance, Cartesian
>>>>> product, link rewriting, threshold)
>>>>> - mm_propagation (SF, propagation graph)
>>>>> - mmw_compare (not equivalence)
>>>>>
>>>>> If you add new extensions, the transformations won't produce any
>>>>> additional result, since they are not aware of the existence of new
>>>>> types of links.
>>>>>
>>>>> Now, looking at your error log, it seems that you don't have any
>>>>> element associated to the "right" reference:
>>>>>
>>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>>
>>>>> The transformations need to have the "left" and "right" references
>>>>> set up in the weaving model.
>>>>>
>>>>> Regards,
>>>>>
>>>>> Marcos.
>>>>>
>>>>>
>>>>> Juan Pedro Silva wrote:
>>>>>> Hi Marcos, sorry for not being clear.
>>>>>> Your answer is of great help to manually generate the
>>>>>> transformations. I'm currently generating the weaving model
>>>>>> manually, but it will take some time to finish due to the size
>>>>>> (moderate, but not small) of the metamodels. After that I'll give
>>>>>> this a try.
>>>>>>
>>>>>> I was referring to the HOT (or "transfGen", as you call it in your
>>>>>> phd Thesis).
>>>>>> I'm having problems with the automatic generation of the
>>>>>> transformation, in various steps.
>>>>>> What I'm trying to do at this point (I postponed the combination
>>>>>> of models until I get this right) is:
>>>>>>
>>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>>> comparison use
>>>>>> case") for my own metamodels.
>>>>>> 2. Manually tune this model with some other wlink extensions
>>>>>> (previously loading my km3 extension).
>>>>>> 3. Generate the ATL transformation (HOT) by means of the AMW
>>>>>> context
>>>>>> menu option.
>>>>>>
>>>>>> However, I'm getting errors in step 1. I can execute the
>>>>>> "Metamodel Match -> Cartesian Product" (takes long but works), but
>>>>>> I get errors when running the "Name Equality" on the cp result
>>>>>> (I'm attaching the console output). I also get an error while
>>>>>> trying step 3 on a partial weaving model, but as the weaving model
>>>>>> was partial and manual, I'll wait until it is complete and try again.
>>>>>>
>>>>>> The question would be, are there any conditions on the metamodels
>>>>>> in order for the matching to work?, and is the available HOT
>>>>>> general enough for using it with our own weaving-metamodel
>>>>>> extensions, or I am supposed to make my own HOTs for them?.
>>>>>>
>>>>>> Thanks again, Marcos.
>>>>>> Regards,
>>>>>> Juan Pedro
>>>>>>
>>>>>>
>>>>>>
>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>
>>>>>>> Hello,
>>>>>>>
>>>>>>> I didn't understand what you mean by "linking the rules with ATL".
>>>>>>>
>>>>>>> You can set the weaving model as input (or output) in the ATL
>>>>>>> transformation, and than use it in different ways. I depict some
>>>>>>> below:
>>>>>>>
>>>>>>> The signature of the transformation would be the following:
>>>>>>>
>>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>>
>>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>>
>>>>>>> rule MatchLink {
>>>>>>>
>>>>>>> from
>>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>>>>>> condition to verify the correct input resource )
>>>>>>>
>>>>>>> to
>>>>>>> out : MMB!Resource (
>>>>>>> action <- -- check for the target resource actions
>>>>>>> -- see the AMW model handler Wiki
>>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check
>>>>>>> how the getReffered() method works)
>>>>>>> )
>>>>>>>
>>>>>>> }
>>>>>>>
>>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>>> search for the linked elements.
>>>>>>>
>>>>>>> rule ActionsToResource {
>>>>>>> from
>>>>>>> cO : MMA!Resource
>>>>>>> to
>>>>>>> out : MMB!Resource
>>>>>>> (
>>>>>>> action <- cO.getOutputActions() -- The helper is
>>>>>>> created for better readability.
>>>>>>> )
>>>>>>> }
>>>>>>>
>>>>>>>
>>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>>> (MMA!Action) =
>>>>>>> -- the helper should search for the ResourceCombination links
>>>>>>> and that returns the model elements based on the values of the
>>>>>>> references targetResource and createAction.
>>>>>>>
>>>>>>>
>>>>>>> Regards,
>>>>>>>
>>>>>>> Marcos.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Juan Pedro Silva wrote:
>>>>>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>>> transformation with the definition of the weaving metamodel
>>>>>>>> extensions.
>>>>>>>>
>>>>>>>> For example, I define the following extension (I based it on the
>>>>>>>> AOM use case):
>>>>>>>>
>>>>>>>> class ResourceCombination extends WLink {
>>>>>>>> -- @subsets end
>>>>>>>> reference targetResource [*] container : Resource;
>>>>>>>> -- @subsets end
>>>>>>>> reference createActions [*] container : Resource;
>>>>>>>> }
>>>>>>>> class Resource extends WLinkEnd {
>>>>>>>> }
>>>>>>>>
>>>>>>>> and now I want to express that, when I draw a
>>>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>>>> "createActions" Resource should be created in the
>>>>>>>> "targetResource" Resource (I want to do more complicated things
>>>>>>>> with it, but lets start with this).
>>>>>>>> In atl, such rule would be:
>>>>>>>>
>>>>>>>> rule ActionsToResource --My
>>>>>>>> guess is that the rule name doesn't affect
>>>>>>>> {
>>>>>>>> from
>>>>>>>> cO : MMA!Resource
>>>>>>>> to
>>>>>>>> out : MMB!Resource
>>>>>>>> (
>>>>>>>> action <- cO.action
>>>>>>>> --where "action" is a set of "Action"
>>>>>>>> elements )
>>>>>>>> }
>>>>>>>>
>>>>>>>> What I don't know how to do is to associate the weaving model
>>>>>>>> (.amw) with the transformation rules (.atl), in order to apply
>>>>>>>> the weavings.
>>>>>>>> How does the linking of the amw extensions with the rules takes
>>>>>>>> place?.
>>>>>>>> Thank you very much.
>>>>>>>> Regards,
>>>>>>>> Juan Pedro
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>> Hello,
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> In aspect oriented modeling, the metamodels are combined. It
>>>>>>>>> would be the creation of MMA + SecureUML metamodel based on
>>>>>>>>> links between MMA and SecureUML.
>>>>>>>>>
>>>>>>>>> Your case seems more similar to the "Merge of geographical
>>>>>>>>> data" use case. http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>>
>>>>>>>>> This is a complex case, where the generated transformation must
>>>>>>>>> take two models as input and produce one model as output. You
>>>>>>>>> need a special extension of AMW to support this kind of
>>>>>>>>> scenario. Take a look on this use case to see if you can get
>>>>>>>>> some inspiration. :) Let me know if you have any other questions.
>>>>>>>>>
>>>>>>>>> Regards,
>>>>>>>>>
>>>>>>>>> Marcos.
>>>>>>>>>
>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>>> I'm trying to use AMW for the first time, and I believe I
>>>>>>>>>> could use some help from people with more knowledge of it than
>>>>>>>>>> me.
>>>>>>>>>>
>>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1' corresponding
>>>>>>>>>> to Meta-Model "A" (something like a simpler version of UML),
>>>>>>>>>> and a second model "IN2", that is a security model that
>>>>>>>>>> corresponds to SecureUML metamodel. I wanted to combine this
>>>>>>>>>> two models into a target model that corresponds to a metamodel
>>>>>>>>>> that is the result of the merging of the first two (see the
>>>>>>>>>> attached picture). This "combination" of the models is more
>>>>>>>>>> than a mere merging.
>>>>>>>>>>
>>>>>>>>>> How could I do this?. In the use cases I saw from the website
>>>>>>>>>> there is always one input model and some matching rules to
>>>>>>>>>> generate one output model (sort of as in a simple ATL
>>>>>>>>>> transformation).
>>>>>>>>>> I tried using the wizard declaring two input models (IN1 and
>>>>>>>>>> IN2) and the output metamodel, but when it comes to choosing
>>>>>>>>>> the input, I can only choose one element from either one of
>>>>>>>>>> the input models.
>>>>>>>>>>
>>>>>>>>>> I believe I'm missing the big picture here, and I surely need
>>>>>>>>>> some advice to get going.
>>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>>> Regards,
>>>>>>>>>> Juan Pedro
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>>
>>>>>>>>>>
Re: Model combination. [message #469559 is a reply to message #469557] Fri, 30 January 2009 11:49 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
You mean the EAnnotation element from the Ecore metamodel?.
There is no "EAnnotation" element in my metamodels (input or output).
There are some comments, however, in the input metamodel which are
expressed as:

<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="Some documentation text"/>
</eAnnotations>

I see there are mapping rules in the "Cartesian Product" result with
right elements EAnnotation (I believe it's allways the right element),
but such a metaclass/element doesn't exist in the target metamodel (I
opened it in a text editor and searched for the "EAnnotation" with no
results), nor does the previously described comments.
Hope this helps.

Marcos Didonet Del Fabro escribió:
>
> It seems something related with the EAnnotation element. Can you
> explain what is it about?
>
> Marcos.
>
> Juan Pedro Silva wrote:
>> Making a new model weaverwith the metamodels in the root folder of
>> the same project has the same results as in the previous one,
>> regretfully.
>>
>> Juan Pedro Silva escribió:
>>> Marcos:
>>>
>>> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
>>> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>>>
>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>>>
>>>
>>> And the .prop.amw file:
>>>
>>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>>> <weaver>
>>> <weaving>
>>> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
>>> <panel>TransformationWeavingPanelExtension</panel>
>>> <wmodel>MatchModel</wmodel>
>>> </weaving>
>>> <metamodels>
>>> <plugin>
>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>>>
>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>>>
>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>>>
>>> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>>>
>>> </plugin>
>>> <local/>
>>> <complete/>
>>> </metamodels>
>>> <woven id="0">
>>> <model-relative-path>null</model-relative-path>
>>> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>>>
>>> <reference>leftM</reference>
>>> <title>leftM</title>
>>> <panel>DefaultWovenPanelExtension</panel>
>>> <wmodelref>ModelRef</wmodelref>
>>> </woven>
>>> <woven id="1">
>>> <model-relative-path>null</model-relative-path>
>>> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>>>
>>> <reference>rightM</reference>
>>> <title>rightM</title>
>>> <panel>DefaultWovenPanelExtension</panel>
>>> <wmodelref>ModelRef</wmodelref>
>>> </woven>
>>> </weaver>
>>>
>>> I load the metamodels in the wizard from other project, do you think
>>> this could create problems?.
>>> I could try copying them into this one and see if that helps.
>>> Regards, and thanks for your help.
>>>
>>>
>>>
>>> Marcos Didonet Del Fabro escribió:
>>>> Hi,
>>>>
>>>> The problem is that it didn't find the right element (it returned a
>>>> "null" in the getElementRef method. However, I cannot say why this
>>>> is happening. Maybe there is a path problem or something related.
>>>>
>>>> Can you copy the value of the "rightM" and "leftM" elements, and
>>>> an excerpt of the .prop.amw.file with the file paths?
>>>>
>>>> The "rightM" element looks like the following:
>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>> ref="/<metamodelpath>.ecore">
>>>>
>>>>
>>>>
>>>> Marcos.
>>>>
>>>> Juan Pedro Silva wrote:
>>>>> Hi Marcos, thanks for your quick answer.
>>>>> Ok on the HOT, I'll work on it.
>>>>> Regarding the matching operations, I was using the extensions you
>>>>> enumerated, and no others. I was following the "Metamodel
>>>>> comparison" use case verbatim with my own metamodels.
>>>>> The input model for the "Name Equality" matching operation was the
>>>>> output of the "cartesian product" operation. Validating this model
>>>>> returns no error or warnings.
>>>>>
>>>>> I looked for the matching rule (in the "_cp.amw") model that shows
>>>>> up in the error stack ("UIComboBox_EAnnotation"), and it has a
>>>>> right element:
>>>>>
>>>>> <ownedElement xsi:type="ElementEqual"
>>>>> name="UIComboBox_EAnnotation" similarity="0.0">
>>>>> <left xsi:type="LeftElement" name="UIComboBox"
>>>>> element="//@leftM/@ownedElementRef.18"/>
>>>>> <right xsi:type="RightElement" name="EAnnotation"
>>>>> element="//@rightM/@ownedElementRef.108"/>
>>>>> </ownedElement>
>>>>>
>>>>> I even navigated throw the "_cp.amw" file (opening it with the
>>>>> text editor) and found no rule that hadn't a right element (this
>>>>> was not exhaustive, though, as there are 223214 lines in that file).
>>>>> Re-running the "Name Equality" operation throws the same error but
>>>>> in a different rule each time.
>>>>> Any ideas?, would size be an issue?. I ask this because it takes
>>>>> quite some time (a couple of minutes) to open this file with the
>>>>> AMW editor, for instance.
>>>>> Regards,
>>>>> Juan Pedro
>>>>>
>>>>>
>>>>> Marcos Didonet Del Fabro escribió:
>>>>>> Hello,
>>>>>>
>>>>>> The matching transformations, as well as the corresponding HOTs,
>>>>>> are implemented based on specific extensions to the AMW core
>>>>>> metamodel. If you want to use new extensions, the HOT must be
>>>>>> extended to be able to support them.
>>>>>>
>>>>>> To execute the matching transformations of the plug-in, the
>>>>>> following extensions are needed:
>>>>>> - mw_base_ext
>>>>>> - mmw_match (equality, cardinality, type and conformance,
>>>>>> Cartesian product, link rewriting, threshold)
>>>>>> - mm_propagation (SF, propagation graph)
>>>>>> - mmw_compare (not equivalence)
>>>>>>
>>>>>> If you add new extensions, the transformations won't produce any
>>>>>> additional result, since they are not aware of the existence of
>>>>>> new types of links.
>>>>>>
>>>>>> Now, looking at your error log, it seems that you don't have any
>>>>>> element associated to the "right" reference:
>>>>>>
>>>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>>>
>>>>>> The transformations need to have the "left" and "right"
>>>>>> references set up in the weaving model.
>>>>>>
>>>>>> Regards,
>>>>>>
>>>>>> Marcos.
>>>>>>
>>>>>>
>>>>>> Juan Pedro Silva wrote:
>>>>>>> Hi Marcos, sorry for not being clear.
>>>>>>> Your answer is of great help to manually generate the
>>>>>>> transformations. I'm currently generating the weaving model
>>>>>>> manually, but it will take some time to finish due to the size
>>>>>>> (moderate, but not small) of the metamodels. After that I'll
>>>>>>> give this a try.
>>>>>>>
>>>>>>> I was referring to the HOT (or "transfGen", as you call it in
>>>>>>> your phd Thesis).
>>>>>>> I'm having problems with the automatic generation of the
>>>>>>> transformation, in various steps.
>>>>>>> What I'm trying to do at this point (I postponed the combination
>>>>>>> of models until I get this right) is:
>>>>>>>
>>>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>>>> comparison use
>>>>>>> case") for my own metamodels.
>>>>>>> 2. Manually tune this model with some other wlink extensions
>>>>>>> (previously loading my km3 extension).
>>>>>>> 3. Generate the ATL transformation (HOT) by means of the AMW
>>>>>>> context
>>>>>>> menu option.
>>>>>>>
>>>>>>> However, I'm getting errors in step 1. I can execute the
>>>>>>> "Metamodel Match -> Cartesian Product" (takes long but works),
>>>>>>> but I get errors when running the "Name Equality" on the cp
>>>>>>> result (I'm attaching the console output). I also get an error
>>>>>>> while trying step 3 on a partial weaving model, but as the
>>>>>>> weaving model was partial and manual, I'll wait until it is
>>>>>>> complete and try again.
>>>>>>>
>>>>>>> The question would be, are there any conditions on the
>>>>>>> metamodels in order for the matching to work?, and is the
>>>>>>> available HOT general enough for using it with our own
>>>>>>> weaving-metamodel extensions, or I am supposed to make my own
>>>>>>> HOTs for them?.
>>>>>>>
>>>>>>> Thanks again, Marcos.
>>>>>>> Regards,
>>>>>>> Juan Pedro
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>
>>>>>>>> Hello,
>>>>>>>>
>>>>>>>> I didn't understand what you mean by "linking the rules with ATL".
>>>>>>>>
>>>>>>>> You can set the weaving model as input (or output) in the ATL
>>>>>>>> transformation, and than use it in different ways. I depict
>>>>>>>> some below:
>>>>>>>>
>>>>>>>> The signature of the transformation would be the following:
>>>>>>>>
>>>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>>>
>>>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>>>
>>>>>>>> rule MatchLink {
>>>>>>>>
>>>>>>>> from
>>>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>>>>>>> condition to verify the correct input resource )
>>>>>>>>
>>>>>>>> to
>>>>>>>> out : MMB!Resource (
>>>>>>>> action <- -- check for the target resource actions
>>>>>>>> -- see the AMW model handler Wiki
>>>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check
>>>>>>>> how the getReffered() method works)
>>>>>>>> )
>>>>>>>>
>>>>>>>> }
>>>>>>>>
>>>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>>>> search for the linked elements.
>>>>>>>>
>>>>>>>> rule ActionsToResource {
>>>>>>>> from
>>>>>>>> cO : MMA!Resource
>>>>>>>> to
>>>>>>>> out : MMB!Resource
>>>>>>>> (
>>>>>>>> action <- cO.getOutputActions() -- The helper is
>>>>>>>> created for better readability.
>>>>>>>> )
>>>>>>>> }
>>>>>>>>
>>>>>>>>
>>>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>>>> (MMA!Action) =
>>>>>>>> -- the helper should search for the ResourceCombination
>>>>>>>> links and that returns the model elements based on the values
>>>>>>>> of the references targetResource and createAction.
>>>>>>>>
>>>>>>>>
>>>>>>>> Regards,
>>>>>>>>
>>>>>>>> Marcos.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>>>> transformation with the definition of the weaving metamodel
>>>>>>>>> extensions.
>>>>>>>>>
>>>>>>>>> For example, I define the following extension (I based it on
>>>>>>>>> the AOM use case):
>>>>>>>>>
>>>>>>>>> class ResourceCombination extends WLink {
>>>>>>>>> -- @subsets end
>>>>>>>>> reference targetResource [*] container : Resource;
>>>>>>>>> -- @subsets end
>>>>>>>>> reference createActions [*] container : Resource;
>>>>>>>>> }
>>>>>>>>> class Resource extends WLinkEnd {
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>> and now I want to express that, when I draw a
>>>>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>>>>> "createActions" Resource should be created in the
>>>>>>>>> "targetResource" Resource (I want to do more complicated
>>>>>>>>> things with it, but lets start with this).
>>>>>>>>> In atl, such rule would be:
>>>>>>>>>
>>>>>>>>> rule ActionsToResource
>>>>>>>>> --My guess is that the rule name doesn't affect
>>>>>>>>> {
>>>>>>>>> from
>>>>>>>>> cO : MMA!Resource
>>>>>>>>> to
>>>>>>>>> out : MMB!Resource
>>>>>>>>> (
>>>>>>>>> action <- cO.action
>>>>>>>>> --where "action" is a set of "Action"
>>>>>>>>> elements )
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>> What I don't know how to do is to associate the weaving model
>>>>>>>>> (.amw) with the transformation rules (.atl), in order to apply
>>>>>>>>> the weavings.
>>>>>>>>> How does the linking of the amw extensions with the rules
>>>>>>>>> takes place?.
>>>>>>>>> Thank you very much.
>>>>>>>>> Regards,
>>>>>>>>> Juan Pedro
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>> Hello,
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> In aspect oriented modeling, the metamodels are combined. It
>>>>>>>>>> would be the creation of MMA + SecureUML metamodel based on
>>>>>>>>>> links between MMA and SecureUML.
>>>>>>>>>>
>>>>>>>>>> Your case seems more similar to the "Merge of geographical
>>>>>>>>>> data" use case.
>>>>>>>>>> http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>>>
>>>>>>>>>> This is a complex case, where the generated transformation
>>>>>>>>>> must take two models as input and produce one model as
>>>>>>>>>> output. You need a special extension of AMW to support this
>>>>>>>>>> kind of scenario. Take a look on this use case to see if you
>>>>>>>>>> can get some inspiration. :) Let me know if you have any
>>>>>>>>>> other questions.
>>>>>>>>>>
>>>>>>>>>> Regards,
>>>>>>>>>>
>>>>>>>>>> Marcos.
>>>>>>>>>>
>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>>>> I'm trying to use AMW for the first time, and I believe I
>>>>>>>>>>> could use some help from people with more knowledge of it
>>>>>>>>>>> than me.
>>>>>>>>>>>
>>>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1'
>>>>>>>>>>> corresponding to Meta-Model "A" (something like a simpler
>>>>>>>>>>> version of UML), and a second model "IN2", that is a
>>>>>>>>>>> security model that corresponds to SecureUML metamodel. I
>>>>>>>>>>> wanted to combine this two models into a target model that
>>>>>>>>>>> corresponds to a metamodel that is the result of the merging
>>>>>>>>>>> of the first two (see the attached picture). This
>>>>>>>>>>> "combination" of the models is more than a mere merging.
>>>>>>>>>>>
>>>>>>>>>>> How could I do this?. In the use cases I saw from the
>>>>>>>>>>> website there is always one input model and some matching
>>>>>>>>>>> rules to generate one output model (sort of as in a simple
>>>>>>>>>>> ATL transformation).
>>>>>>>>>>> I tried using the wizard declaring two input models (IN1 and
>>>>>>>>>>> IN2) and the output metamodel, but when it comes to choosing
>>>>>>>>>>> the input, I can only choose one element from either one of
>>>>>>>>>>> the input models.
>>>>>>>>>>>
>>>>>>>>>>> I believe I'm missing the big picture here, and I surely
>>>>>>>>>>> need some advice to get going.
>>>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>>>> Regards,
>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>>>
>>>>>>>>>>>
Re: Model combination. [message #469561 is a reply to message #469559] Fri, 30 January 2009 12:19 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
Hello,

I think I know the problem. One of the metamodels (right) refers to some
elements from Ecore, for instance, datatypes such as EString, EBoolean,
EInteger.

In this case, the EMF model handler resolves this reference, and it
"includes" all Ecore into the metamodel, so the matching transformation
will also match elements such as EAnnotation, EClass,
EStructuralFeature, etc.
These references should be deleted to be able to correctly execute the
matching transformations.

When creating "clean" metamodels, this practice should be avoided. In
the case of data types, the better solution is to create a package
"DataTypes" and create the corresponding data types (String, Double,
etc). This is how we proceed when creating KM3 or Ecore metamodels. You
can find examples int the ATL or AMW use cases page.

Regards,

Marcos.

Juan Pedro Silva wrote:
> You mean the EAnnotation element from the Ecore metamodel?.
> There is no "EAnnotation" element in my metamodels (input or output).
> There are some comments, however, in the input metamodel which are
> expressed as:
>
> <eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
> <details key="documentation" value="Some documentation text"/>
> </eAnnotations>
>
> I see there are mapping rules in the "Cartesian Product" result with
> right elements EAnnotation (I believe it's allways the right element),
> but such a metaclass/element doesn't exist in the target metamodel (I
> opened it in a text editor and searched for the "EAnnotation" with no
> results), nor does the previously described comments.
> Hope this helps.
>
> Marcos Didonet Del Fabro escribió:
>>
>> It seems something related with the EAnnotation element. Can you
>> explain what is it about?
>>
>> Marcos.
>>
>> Juan Pedro Silva wrote:
>>> Making a new model weaverwith the metamodels in the root folder of
>>> the same project has the same results as in the previous one,
>>> regretfully.
>>>
>>> Juan Pedro Silva escribió:
>>>> Marcos:
>>>>
>>>> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
>>>> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>>>>
>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>>>>
>>>>
>>>> And the .prop.amw file:
>>>>
>>>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>>>> <weaver>
>>>> <weaving>
>>>> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
>>>> <panel>TransformationWeavingPanelExtension</panel>
>>>> <wmodel>MatchModel</wmodel>
>>>> </weaving>
>>>> <metamodels>
>>>> <plugin>
>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>>>>
>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>>>>
>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>>>>
>>>> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>>>>
>>>> </plugin>
>>>> <local/>
>>>> <complete/>
>>>> </metamodels>
>>>> <woven id="0">
>>>> <model-relative-path>null</model-relative-path>
>>>> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>>>>
>>>> <reference>leftM</reference>
>>>> <title>leftM</title>
>>>> <panel>DefaultWovenPanelExtension</panel>
>>>> <wmodelref>ModelRef</wmodelref>
>>>> </woven>
>>>> <woven id="1">
>>>> <model-relative-path>null</model-relative-path>
>>>> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>>>>
>>>> <reference>rightM</reference>
>>>> <title>rightM</title>
>>>> <panel>DefaultWovenPanelExtension</panel>
>>>> <wmodelref>ModelRef</wmodelref>
>>>> </woven>
>>>> </weaver>
>>>>
>>>> I load the metamodels in the wizard from other project, do you think
>>>> this could create problems?.
>>>> I could try copying them into this one and see if that helps.
>>>> Regards, and thanks for your help.
>>>>
>>>>
>>>>
>>>> Marcos Didonet Del Fabro escribió:
>>>>> Hi,
>>>>>
>>>>> The problem is that it didn't find the right element (it returned a
>>>>> "null" in the getElementRef method. However, I cannot say why this
>>>>> is happening. Maybe there is a path problem or something related.
>>>>>
>>>>> Can you copy the value of the "rightM" and "leftM" elements, and
>>>>> an excerpt of the .prop.amw.file with the file paths?
>>>>>
>>>>> The "rightM" element looks like the following:
>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>>> ref="/<metamodelpath>.ecore">
>>>>>
>>>>>
>>>>>
>>>>> Marcos.
>>>>>
>>>>> Juan Pedro Silva wrote:
>>>>>> Hi Marcos, thanks for your quick answer.
>>>>>> Ok on the HOT, I'll work on it.
>>>>>> Regarding the matching operations, I was using the extensions you
>>>>>> enumerated, and no others. I was following the "Metamodel
>>>>>> comparison" use case verbatim with my own metamodels.
>>>>>> The input model for the "Name Equality" matching operation was the
>>>>>> output of the "cartesian product" operation. Validating this model
>>>>>> returns no error or warnings.
>>>>>>
>>>>>> I looked for the matching rule (in the "_cp.amw") model that shows
>>>>>> up in the error stack ("UIComboBox_EAnnotation"), and it has a
>>>>>> right element:
>>>>>>
>>>>>> <ownedElement xsi:type="ElementEqual"
>>>>>> name="UIComboBox_EAnnotation" similarity="0.0">
>>>>>> <left xsi:type="LeftElement" name="UIComboBox"
>>>>>> element="//@leftM/@ownedElementRef.18"/>
>>>>>> <right xsi:type="RightElement" name="EAnnotation"
>>>>>> element="//@rightM/@ownedElementRef.108"/>
>>>>>> </ownedElement>
>>>>>>
>>>>>> I even navigated throw the "_cp.amw" file (opening it with the
>>>>>> text editor) and found no rule that hadn't a right element (this
>>>>>> was not exhaustive, though, as there are 223214 lines in that file).
>>>>>> Re-running the "Name Equality" operation throws the same error but
>>>>>> in a different rule each time.
>>>>>> Any ideas?, would size be an issue?. I ask this because it takes
>>>>>> quite some time (a couple of minutes) to open this file with the
>>>>>> AMW editor, for instance.
>>>>>> Regards,
>>>>>> Juan Pedro
>>>>>>
>>>>>>
>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>> Hello,
>>>>>>>
>>>>>>> The matching transformations, as well as the corresponding HOTs,
>>>>>>> are implemented based on specific extensions to the AMW core
>>>>>>> metamodel. If you want to use new extensions, the HOT must be
>>>>>>> extended to be able to support them.
>>>>>>>
>>>>>>> To execute the matching transformations of the plug-in, the
>>>>>>> following extensions are needed:
>>>>>>> - mw_base_ext
>>>>>>> - mmw_match (equality, cardinality, type and conformance,
>>>>>>> Cartesian product, link rewriting, threshold)
>>>>>>> - mm_propagation (SF, propagation graph)
>>>>>>> - mmw_compare (not equivalence)
>>>>>>>
>>>>>>> If you add new extensions, the transformations won't produce any
>>>>>>> additional result, since they are not aware of the existence of
>>>>>>> new types of links.
>>>>>>>
>>>>>>> Now, looking at your error log, it seems that you don't have any
>>>>>>> element associated to the "right" reference:
>>>>>>>
>>>>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>>>>
>>>>>>> The transformations need to have the "left" and "right"
>>>>>>> references set up in the weaving model.
>>>>>>>
>>>>>>> Regards,
>>>>>>>
>>>>>>> Marcos.
>>>>>>>
>>>>>>>
>>>>>>> Juan Pedro Silva wrote:
>>>>>>>> Hi Marcos, sorry for not being clear.
>>>>>>>> Your answer is of great help to manually generate the
>>>>>>>> transformations. I'm currently generating the weaving model
>>>>>>>> manually, but it will take some time to finish due to the size
>>>>>>>> (moderate, but not small) of the metamodels. After that I'll
>>>>>>>> give this a try.
>>>>>>>>
>>>>>>>> I was referring to the HOT (or "transfGen", as you call it in
>>>>>>>> your phd Thesis).
>>>>>>>> I'm having problems with the automatic generation of the
>>>>>>>> transformation, in various steps.
>>>>>>>> What I'm trying to do at this point (I postponed the combination
>>>>>>>> of models until I get this right) is:
>>>>>>>>
>>>>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>>>>> comparison use
>>>>>>>> case") for my own metamodels.
>>>>>>>> 2. Manually tune this model with some other wlink extensions
>>>>>>>> (previously loading my km3 extension).
>>>>>>>> 3. Generate the ATL transformation (HOT) by means of the AMW
>>>>>>>> context
>>>>>>>> menu option.
>>>>>>>>
>>>>>>>> However, I'm getting errors in step 1. I can execute the
>>>>>>>> "Metamodel Match -> Cartesian Product" (takes long but works),
>>>>>>>> but I get errors when running the "Name Equality" on the cp
>>>>>>>> result (I'm attaching the console output). I also get an error
>>>>>>>> while trying step 3 on a partial weaving model, but as the
>>>>>>>> weaving model was partial and manual, I'll wait until it is
>>>>>>>> complete and try again.
>>>>>>>>
>>>>>>>> The question would be, are there any conditions on the
>>>>>>>> metamodels in order for the matching to work?, and is the
>>>>>>>> available HOT general enough for using it with our own
>>>>>>>> weaving-metamodel extensions, or I am supposed to make my own
>>>>>>>> HOTs for them?.
>>>>>>>>
>>>>>>>> Thanks again, Marcos.
>>>>>>>> Regards,
>>>>>>>> Juan Pedro
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>
>>>>>>>>> Hello,
>>>>>>>>>
>>>>>>>>> I didn't understand what you mean by "linking the rules with ATL".
>>>>>>>>>
>>>>>>>>> You can set the weaving model as input (or output) in the ATL
>>>>>>>>> transformation, and than use it in different ways. I depict
>>>>>>>>> some below:
>>>>>>>>>
>>>>>>>>> The signature of the transformation would be the following:
>>>>>>>>>
>>>>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>>>>
>>>>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>>>>
>>>>>>>>> rule MatchLink {
>>>>>>>>>
>>>>>>>>> from
>>>>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource (some
>>>>>>>>> condition to verify the correct input resource )
>>>>>>>>>
>>>>>>>>> to
>>>>>>>>> out : MMB!Resource (
>>>>>>>>> action <- -- check for the target resource actions
>>>>>>>>> -- see the AMW model handler Wiki
>>>>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to check
>>>>>>>>> how the getReffered() method works)
>>>>>>>>> )
>>>>>>>>>
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>>>>> search for the linked elements.
>>>>>>>>>
>>>>>>>>> rule ActionsToResource {
>>>>>>>>> from
>>>>>>>>> cO : MMA!Resource
>>>>>>>>> to
>>>>>>>>> out : MMB!Resource
>>>>>>>>> (
>>>>>>>>> action <- cO.getOutputActions() -- The helper is
>>>>>>>>> created for better readability.
>>>>>>>>> )
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>>>>> (MMA!Action) =
>>>>>>>>> -- the helper should search for the ResourceCombination
>>>>>>>>> links and that returns the model elements based on the values
>>>>>>>>> of the references targetResource and createAction.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Regards,
>>>>>>>>>
>>>>>>>>> Marcos.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>> Marcos, I'm back to this after some time doing some other stuff.
>>>>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>>>>> transformation with the definition of the weaving metamodel
>>>>>>>>>> extensions.
>>>>>>>>>>
>>>>>>>>>> For example, I define the following extension (I based it on
>>>>>>>>>> the AOM use case):
>>>>>>>>>>
>>>>>>>>>> class ResourceCombination extends WLink {
>>>>>>>>>> -- @subsets end
>>>>>>>>>> reference targetResource [*] container : Resource;
>>>>>>>>>> -- @subsets end
>>>>>>>>>> reference createActions [*] container : Resource;
>>>>>>>>>> }
>>>>>>>>>> class Resource extends WLinkEnd {
>>>>>>>>>> }
>>>>>>>>>>
>>>>>>>>>> and now I want to express that, when I draw a
>>>>>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>>>>>> "createActions" Resource should be created in the
>>>>>>>>>> "targetResource" Resource (I want to do more complicated
>>>>>>>>>> things with it, but lets start with this).
>>>>>>>>>> In atl, such rule would be:
>>>>>>>>>>
>>>>>>>>>> rule ActionsToResource
>>>>>>>>>> --My guess is that the rule name doesn't affect
>>>>>>>>>> {
>>>>>>>>>> from
>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>> to
>>>>>>>>>> out : MMB!Resource
>>>>>>>>>> (
>>>>>>>>>> action <- cO.action
>>>>>>>>>> --where "action" is a set of "Action"
>>>>>>>>>> elements )
>>>>>>>>>> }
>>>>>>>>>>
>>>>>>>>>> What I don't know how to do is to associate the weaving model
>>>>>>>>>> (.amw) with the transformation rules (.atl), in order to apply
>>>>>>>>>> the weavings.
>>>>>>>>>> How does the linking of the amw extensions with the rules
>>>>>>>>>> takes place?.
>>>>>>>>>> Thank you very much.
>>>>>>>>>> Regards,
>>>>>>>>>> Juan Pedro
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>> Hello,
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> In aspect oriented modeling, the metamodels are combined. It
>>>>>>>>>>> would be the creation of MMA + SecureUML metamodel based on
>>>>>>>>>>> links between MMA and SecureUML.
>>>>>>>>>>>
>>>>>>>>>>> Your case seems more similar to the "Merge of geographical
>>>>>>>>>>> data" use case.
>>>>>>>>>>> http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>>>>
>>>>>>>>>>> This is a complex case, where the generated transformation
>>>>>>>>>>> must take two models as input and produce one model as
>>>>>>>>>>> output. You need a special extension of AMW to support this
>>>>>>>>>>> kind of scenario. Take a look on this use case to see if you
>>>>>>>>>>> can get some inspiration. :) Let me know if you have any
>>>>>>>>>>> other questions.
>>>>>>>>>>>
>>>>>>>>>>> Regards,
>>>>>>>>>>>
>>>>>>>>>>> Marcos.
>>>>>>>>>>>
>>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>>>>> I'm trying to use AMW for the first time, and I believe I
>>>>>>>>>>>> could use some help from people with more knowledge of it
>>>>>>>>>>>> than me.
>>>>>>>>>>>>
>>>>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1'
>>>>>>>>>>>> corresponding to Meta-Model "A" (something like a simpler
>>>>>>>>>>>> version of UML), and a second model "IN2", that is a
>>>>>>>>>>>> security model that corresponds to SecureUML metamodel. I
>>>>>>>>>>>> wanted to combine this two models into a target model that
>>>>>>>>>>>> corresponds to a metamodel that is the result of the merging
>>>>>>>>>>>> of the first two (see the attached picture). This
>>>>>>>>>>>> "combination" of the models is more than a mere merging.
>>>>>>>>>>>>
>>>>>>>>>>>> How could I do this?. In the use cases I saw from the
>>>>>>>>>>>> website there is always one input model and some matching
>>>>>>>>>>>> rules to generate one output model (sort of as in a simple
>>>>>>>>>>>> ATL transformation).
>>>>>>>>>>>> I tried using the wizard declaring two input models (IN1 and
>>>>>>>>>>>> IN2) and the output metamodel, but when it comes to choosing
>>>>>>>>>>>> the input, I can only choose one element from either one of
>>>>>>>>>>>> the input models.
>>>>>>>>>>>>
>>>>>>>>>>>> I believe I'm missing the big picture here, and I surely
>>>>>>>>>>>> need some advice to get going.
>>>>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>>>>> Regards,
>>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>>>>
>>>>>>>>>>>>
Re: Model combination. [message #469564 is a reply to message #469561] Fri, 30 January 2009 20:18 Go to previous messageGo to next message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
Marcos, you were right: deleting the EAnnotation elements made it work.
Thanks.
I have one more question, regarding enumerations. I see enumerations are
not being matched. If I match them manually (using "Element Equal" for
enums and "Attribute Equal" for literals), the HOT generation throws an
error (feature abstract does not exist in MOF!EEnum).

I don't know if this is the same issue as with EAnnotations, being
Enumeration a MOF element and all.
Perhaps I should use another type of link (instead of "Element Equal"),
one that the HOT doesn't check for the elements to be abstract. Any
suggestions?.

Best regards and thank you very much for all your help,

Juan Pedro



Marcos Didonet Del Fabro escribió:
> Hello,
>
> I think I know the problem. One of the metamodels (right) refers to
> some elements from Ecore, for instance, datatypes such as EString,
> EBoolean, EInteger.
>
> In this case, the EMF model handler resolves this reference, and it
> "includes" all Ecore into the metamodel, so the matching
> transformation will also match elements such as EAnnotation, EClass,
> EStructuralFeature, etc.
> These references should be deleted to be able to correctly execute the
> matching transformations.
>
> When creating "clean" metamodels, this practice should be avoided. In
> the case of data types, the better solution is to create a package
> "DataTypes" and create the corresponding data types (String, Double,
> etc). This is how we proceed when creating KM3 or Ecore metamodels.
> You can find examples int the ATL or AMW use cases page.
>
> Regards,
>
> Marcos.
>
> Juan Pedro Silva wrote:
>> You mean the EAnnotation element from the Ecore metamodel?.
>> There is no "EAnnotation" element in my metamodels (input or output).
>> There are some comments, however, in the input metamodel which are
>> expressed as:
>>
>> <eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
>> <details key="documentation" value="Some documentation text"/>
>> </eAnnotations>
>>
>> I see there are mapping rules in the "Cartesian Product" result with
>> right elements EAnnotation (I believe it's allways the right
>> element), but such a metaclass/element doesn't exist in the target
>> metamodel (I opened it in a text editor and searched for the
>> "EAnnotation" with no results), nor does the previously described
>> comments.
>> Hope this helps.
>>
>> Marcos Didonet Del Fabro escribió:
>>>
>>> It seems something related with the EAnnotation element. Can you
>>> explain what is it about?
>>>
>>> Marcos.
>>>
>>> Juan Pedro Silva wrote:
>>>> Making a new model weaverwith the metamodels in the root folder of
>>>> the same project has the same results as in the previous one,
>>>> regretfully.
>>>>
>>>> Juan Pedro Silva escribió:
>>>>> Marcos:
>>>>>
>>>>> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
>>>>> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>>>>>
>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>>> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>>>>>
>>>>>
>>>>> And the .prop.amw file:
>>>>>
>>>>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>>>>> <weaver>
>>>>> <weaving>
>>>>> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
>>>>> <panel>TransformationWeavingPanelExtension</panel>
>>>>> <wmodel>MatchModel</wmodel>
>>>>> </weaving>
>>>>> <metamodels>
>>>>> <plugin>
>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>>>>>
>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>>>>>
>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>>>>>
>>>>> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>>>>>
>>>>> </plugin>
>>>>> <local/>
>>>>> <complete/>
>>>>> </metamodels>
>>>>> <woven id="0">
>>>>> <model-relative-path>null</model-relative-path>
>>>>> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>>>>>
>>>>> <reference>leftM</reference>
>>>>> <title>leftM</title>
>>>>> <panel>DefaultWovenPanelExtension</panel>
>>>>> <wmodelref>ModelRef</wmodelref>
>>>>> </woven>
>>>>> <woven id="1">
>>>>> <model-relative-path>null</model-relative-path>
>>>>> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>>>>>
>>>>> <reference>rightM</reference>
>>>>> <title>rightM</title>
>>>>> <panel>DefaultWovenPanelExtension</panel>
>>>>> <wmodelref>ModelRef</wmodelref>
>>>>> </woven>
>>>>> </weaver>
>>>>>
>>>>> I load the metamodels in the wizard from other project, do you
>>>>> think this could create problems?.
>>>>> I could try copying them into this one and see if that helps.
>>>>> Regards, and thanks for your help.
>>>>>
>>>>>
>>>>>
>>>>> Marcos Didonet Del Fabro escribió:
>>>>>> Hi,
>>>>>>
>>>>>> The problem is that it didn't find the right element (it returned
>>>>>> a "null" in the getElementRef method. However, I cannot say why
>>>>>> this is happening. Maybe there is a path problem or something
>>>>>> related.
>>>>>>
>>>>>> Can you copy the value of the "rightM" and "leftM" elements, and
>>>>>> an excerpt of the .prop.amw.file with the file paths?
>>>>>>
>>>>>> The "rightM" element looks like the following:
>>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>>>> ref="/<metamodelpath>.ecore">
>>>>>>
>>>>>>
>>>>>>
>>>>>> Marcos.
>>>>>>
>>>>>> Juan Pedro Silva wrote:
>>>>>>> Hi Marcos, thanks for your quick answer.
>>>>>>> Ok on the HOT, I'll work on it.
>>>>>>> Regarding the matching operations, I was using the extensions
>>>>>>> you enumerated, and no others. I was following the "Metamodel
>>>>>>> comparison" use case verbatim with my own metamodels.
>>>>>>> The input model for the "Name Equality" matching operation was
>>>>>>> the output of the "cartesian product" operation. Validating this
>>>>>>> model returns no error or warnings.
>>>>>>>
>>>>>>> I looked for the matching rule (in the "_cp.amw") model that
>>>>>>> shows up in the error stack ("UIComboBox_EAnnotation"), and it
>>>>>>> has a right element:
>>>>>>>
>>>>>>> <ownedElement xsi:type="ElementEqual"
>>>>>>> name="UIComboBox_EAnnotation" similarity="0.0">
>>>>>>> <left xsi:type="LeftElement" name="UIComboBox"
>>>>>>> element="//@leftM/@ownedElementRef.18"/>
>>>>>>> <right xsi:type="RightElement" name="EAnnotation"
>>>>>>> element="//@rightM/@ownedElementRef.108"/>
>>>>>>> </ownedElement>
>>>>>>>
>>>>>>> I even navigated throw the "_cp.amw" file (opening it with the
>>>>>>> text editor) and found no rule that hadn't a right element (this
>>>>>>> was not exhaustive, though, as there are 223214 lines in that
>>>>>>> file).
>>>>>>> Re-running the "Name Equality" operation throws the same error
>>>>>>> but in a different rule each time.
>>>>>>> Any ideas?, would size be an issue?. I ask this because it takes
>>>>>>> quite some time (a couple of minutes) to open this file with the
>>>>>>> AMW editor, for instance.
>>>>>>> Regards,
>>>>>>> Juan Pedro
>>>>>>>
>>>>>>>
>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>> Hello,
>>>>>>>>
>>>>>>>> The matching transformations, as well as the corresponding
>>>>>>>> HOTs, are implemented based on specific extensions to the AMW
>>>>>>>> core metamodel. If you want to use new extensions, the HOT must
>>>>>>>> be extended to be able to support them.
>>>>>>>>
>>>>>>>> To execute the matching transformations of the plug-in, the
>>>>>>>> following extensions are needed:
>>>>>>>> - mw_base_ext
>>>>>>>> - mmw_match (equality, cardinality, type and conformance,
>>>>>>>> Cartesian product, link rewriting, threshold)
>>>>>>>> - mm_propagation (SF, propagation graph)
>>>>>>>> - mmw_compare (not equivalence)
>>>>>>>>
>>>>>>>> If you add new extensions, the transformations won't produce
>>>>>>>> any additional result, since they are not aware of the
>>>>>>>> existence of new types of links.
>>>>>>>>
>>>>>>>> Now, looking at your error log, it seems that you don't have
>>>>>>>> any element associated to the "right" reference:
>>>>>>>>
>>>>>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>>>>>
>>>>>>>> The transformations need to have the "left" and "right"
>>>>>>>> references set up in the weaving model.
>>>>>>>>
>>>>>>>> Regards,
>>>>>>>>
>>>>>>>> Marcos.
>>>>>>>>
>>>>>>>>
>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>> Hi Marcos, sorry for not being clear.
>>>>>>>>> Your answer is of great help to manually generate the
>>>>>>>>> transformations. I'm currently generating the weaving model
>>>>>>>>> manually, but it will take some time to finish due to the size
>>>>>>>>> (moderate, but not small) of the metamodels. After that I'll
>>>>>>>>> give this a try.
>>>>>>>>>
>>>>>>>>> I was referring to the HOT (or "transfGen", as you call it in
>>>>>>>>> your phd Thesis).
>>>>>>>>> I'm having problems with the automatic generation of the
>>>>>>>>> transformation, in various steps.
>>>>>>>>> What I'm trying to do at this point (I postponed the
>>>>>>>>> combination of models until I get this right) is:
>>>>>>>>>
>>>>>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>>>>>> comparison use
>>>>>>>>> case") for my own metamodels.
>>>>>>>>> 2. Manually tune this model with some other wlink extensions
>>>>>>>>> (previously loading my km3 extension).
>>>>>>>>> 3. Generate the ATL transformation (HOT) by means of the
>>>>>>>>> AMW context
>>>>>>>>> menu option.
>>>>>>>>>
>>>>>>>>> However, I'm getting errors in step 1. I can execute the
>>>>>>>>> "Metamodel Match -> Cartesian Product" (takes long but works),
>>>>>>>>> but I get errors when running the "Name Equality" on the cp
>>>>>>>>> result (I'm attaching the console output). I also get an error
>>>>>>>>> while trying step 3 on a partial weaving model, but as the
>>>>>>>>> weaving model was partial and manual, I'll wait until it is
>>>>>>>>> complete and try again.
>>>>>>>>>
>>>>>>>>> The question would be, are there any conditions on the
>>>>>>>>> metamodels in order for the matching to work?, and is the
>>>>>>>>> available HOT general enough for using it with our own
>>>>>>>>> weaving-metamodel extensions, or I am supposed to make my own
>>>>>>>>> HOTs for them?.
>>>>>>>>>
>>>>>>>>> Thanks again, Marcos.
>>>>>>>>> Regards,
>>>>>>>>> Juan Pedro
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>
>>>>>>>>>> Hello,
>>>>>>>>>>
>>>>>>>>>> I didn't understand what you mean by "linking the rules with
>>>>>>>>>> ATL".
>>>>>>>>>>
>>>>>>>>>> You can set the weaving model as input (or output) in the ATL
>>>>>>>>>> transformation, and than use it in different ways. I depict
>>>>>>>>>> some below:
>>>>>>>>>>
>>>>>>>>>> The signature of the transformation would be the following:
>>>>>>>>>>
>>>>>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>>>>>
>>>>>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>>>>>
>>>>>>>>>> rule MatchLink {
>>>>>>>>>>
>>>>>>>>>> from
>>>>>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource
>>>>>>>>>> (some condition to verify the correct input resource )
>>>>>>>>>>
>>>>>>>>>> to
>>>>>>>>>> out : MMB!Resource (
>>>>>>>>>> action <- -- check for the target resource actions
>>>>>>>>>> -- see the AMW model handler Wiki
>>>>>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to
>>>>>>>>>> check how the getReffered() method works)
>>>>>>>>>> )
>>>>>>>>>>
>>>>>>>>>> }
>>>>>>>>>>
>>>>>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>>>>>> search for the linked elements.
>>>>>>>>>>
>>>>>>>>>> rule ActionsToResource {
>>>>>>>>>> from
>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>> to
>>>>>>>>>> out : MMB!Resource
>>>>>>>>>> (
>>>>>>>>>> action <- cO.getOutputActions() -- The helper
>>>>>>>>>> is created for better readability.
>>>>>>>>>> )
>>>>>>>>>> }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>>>>>> (MMA!Action) =
>>>>>>>>>> -- the helper should search for the ResourceCombination
>>>>>>>>>> links and that returns the model elements based on the values
>>>>>>>>>> of the references targetResource and createAction.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Regards,
>>>>>>>>>>
>>>>>>>>>> Marcos.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>> Marcos, I'm back to this after some time doing some other
>>>>>>>>>>> stuff.
>>>>>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>>>>>> transformation with the definition of the weaving metamodel
>>>>>>>>>>> extensions.
>>>>>>>>>>>
>>>>>>>>>>> For example, I define the following extension (I based it on
>>>>>>>>>>> the AOM use case):
>>>>>>>>>>>
>>>>>>>>>>> class ResourceCombination extends WLink {
>>>>>>>>>>> -- @subsets end
>>>>>>>>>>> reference targetResource [*] container : Resource;
>>>>>>>>>>> -- @subsets end
>>>>>>>>>>> reference createActions [*] container : Resource;
>>>>>>>>>>> }
>>>>>>>>>>> class Resource extends WLinkEnd {
>>>>>>>>>>> }
>>>>>>>>>>>
>>>>>>>>>>> and now I want to express that, when I draw a
>>>>>>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>>>>>>> "createActions" Resource should be created in the
>>>>>>>>>>> "targetResource" Resource (I want to do more complicated
>>>>>>>>>>> things with it, but lets start with this).
>>>>>>>>>>> In atl, such rule would be:
>>>>>>>>>>>
>>>>>>>>>>> rule ActionsToResource
>>>>>>>>>>> --My guess is that the rule name doesn't affect
>>>>>>>>>>> {
>>>>>>>>>>> from
>>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>>> to
>>>>>>>>>>> out : MMB!Resource
>>>>>>>>>>> (
>>>>>>>>>>> action <- cO.action
>>>>>>>>>>> --where "action" is a set of "Action"
>>>>>>>>>>> elements )
>>>>>>>>>>> }
>>>>>>>>>>>
>>>>>>>>>>> What I don't know how to do is to associate the weaving
>>>>>>>>>>> model (.amw) with the transformation rules (.atl), in order
>>>>>>>>>>> to apply the weavings.
>>>>>>>>>>> How does the linking of the amw extensions with the rules
>>>>>>>>>>> takes place?.
>>>>>>>>>>> Thank you very much.
>>>>>>>>>>> Regards,
>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>>> Hello,
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> In aspect oriented modeling, the metamodels are combined.
>>>>>>>>>>>> It would be the creation of MMA + SecureUML metamodel based
>>>>>>>>>>>> on links between MMA and SecureUML.
>>>>>>>>>>>>
>>>>>>>>>>>> Your case seems more similar to the "Merge of geographical
>>>>>>>>>>>> data" use case.
>>>>>>>>>>>> http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>>>>>
>>>>>>>>>>>> This is a complex case, where the generated transformation
>>>>>>>>>>>> must take two models as input and produce one model as
>>>>>>>>>>>> output. You need a special extension of AMW to support this
>>>>>>>>>>>> kind of scenario. Take a look on this use case to see if
>>>>>>>>>>>> you can get some inspiration. :) Let me know if you have
>>>>>>>>>>>> any other questions.
>>>>>>>>>>>>
>>>>>>>>>>>> Regards,
>>>>>>>>>>>>
>>>>>>>>>>>> Marcos.
>>>>>>>>>>>>
>>>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>>>>>> I'm trying to use AMW for the first time, and I believe I
>>>>>>>>>>>>> could use some help from people with more knowledge of it
>>>>>>>>>>>>> than me.
>>>>>>>>>>>>>
>>>>>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1'
>>>>>>>>>>>>> corresponding to Meta-Model "A" (something like a simpler
>>>>>>>>>>>>> version of UML), and a second model "IN2", that is a
>>>>>>>>>>>>> security model that corresponds to SecureUML metamodel. I
>>>>>>>>>>>>> wanted to combine this two models into a target model that
>>>>>>>>>>>>> corresponds to a metamodel that is the result of the
>>>>>>>>>>>>> merging of the first two (see the attached picture). This
>>>>>>>>>>>>> "combination" of the models is more than a mere merging.
>>>>>>>>>>>>>
>>>>>>>>>>>>> How could I do this?. In the use cases I saw from the
>>>>>>>>>>>>> website there is always one input model and some matching
>>>>>>>>>>>>> rules to generate one output model (sort of as in a simple
>>>>>>>>>>>>> ATL transformation).
>>>>>>>>>>>>> I tried using the wizard declaring two input models (IN1
>>>>>>>>>>>>> and IN2) and the output metamodel, but when it comes to
>>>>>>>>>>>>> choosing the input, I can only choose one element from
>>>>>>>>>>>>> either one of the input models.
>>>>>>>>>>>>>
>>>>>>>>>>>>> I believe I'm missing the big picture here, and I surely
>>>>>>>>>>>>> need some advice to get going.
>>>>>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>>>>>> Regards,
>>>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>>>>>
>>>>>>>>>>>>>
Re: Model combination. [message #469567 is a reply to message #469564] Mon, 02 February 2009 04:30 Go to previous messageGo to next message
Marcos Didonet Del Fabro is currently offline Marcos Didonet Del Fabro
Messages: 84
Registered: July 2009
Member
Hello,

The matching transformations do not create links between enumerations.
We didn't implement the support to enumerations in the HOT. The HOT has
a rule that matches "ElementEqual" links, and it expects that they
connect two classes, so it tests the "abstract" property. That's why it
does not work.

You can create a different kind of link, though the current HOT won't
produce any extra result (but there will be no errors). You can, of
course, improve the HOT implementation to handle enumerations.


Regards,

Marcos.

Juan Pedro Silva wrote:
> Marcos, you were right: deleting the EAnnotation elements made it work.
> Thanks.
> I have one more question, regarding enumerations. I see enumerations are
> not being matched. If I match them manually (using "Element Equal" for
> enums and "Attribute Equal" for literals), the HOT generation throws an
> error (feature abstract does not exist in MOF!EEnum).
>
> I don't know if this is the same issue as with EAnnotations, being
> Enumeration a MOF element and all.
> Perhaps I should use another type of link (instead of "Element Equal"),
> one that the HOT doesn't check for the elements to be abstract. Any
> suggestions?.
>
> Best regards and thank you very much for all your help,
> Juan
> Pedro
>
>
>
> Marcos Didonet Del Fabro escribió:
>> Hello,
>>
>> I think I know the problem. One of the metamodels (right) refers to
>> some elements from Ecore, for instance, datatypes such as EString,
>> EBoolean, EInteger.
>>
>> In this case, the EMF model handler resolves this reference, and it
>> "includes" all Ecore into the metamodel, so the matching
>> transformation will also match elements such as EAnnotation, EClass,
>> EStructuralFeature, etc.
>> These references should be deleted to be able to correctly execute the
>> matching transformations.
>>
>> When creating "clean" metamodels, this practice should be avoided. In
>> the case of data types, the better solution is to create a package
>> "DataTypes" and create the corresponding data types (String, Double,
>> etc). This is how we proceed when creating KM3 or Ecore metamodels.
>> You can find examples int the ATL or AMW use cases page.
>>
>> Regards,
>>
>> Marcos.
>>
>> Juan Pedro Silva wrote:
>>> You mean the EAnnotation element from the Ecore metamodel?.
>>> There is no "EAnnotation" element in my metamodels (input or output).
>>> There are some comments, however, in the input metamodel which are
>>> expressed as:
>>>
>>> <eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
>>> <details key="documentation" value="Some documentation text"/>
>>> </eAnnotations>
>>>
>>> I see there are mapping rules in the "Cartesian Product" result with
>>> right elements EAnnotation (I believe it's allways the right
>>> element), but such a metaclass/element doesn't exist in the target
>>> metamodel (I opened it in a text editor and searched for the
>>> "EAnnotation" with no results), nor does the previously described
>>> comments.
>>> Hope this helps.
>>>
>>> Marcos Didonet Del Fabro escribió:
>>>>
>>>> It seems something related with the EAnnotation element. Can you
>>>> explain what is it about?
>>>>
>>>> Marcos.
>>>>
>>>> Juan Pedro Silva wrote:
>>>>> Making a new model weaverwith the metamodels in the root folder of
>>>>> the same project has the same results as in the previous one,
>>>>> regretfully.
>>>>>
>>>>> Juan Pedro Silva escribió:
>>>>>> Marcos:
>>>>>>
>>>>>> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
>>>>>> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>>>>>>
>>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>>>> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>>>>>>
>>>>>>
>>>>>> And the .prop.amw file:
>>>>>>
>>>>>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>>>>>> <weaver>
>>>>>> <weaving>
>>>>>> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
>>>>>> <panel>TransformationWeavingPanelExtension</panel>
>>>>>> <wmodel>MatchModel</wmodel>
>>>>>> </weaving>
>>>>>> <metamodels>
>>>>>> <plugin>
>>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>>>>>>
>>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>>>>>>
>>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>>>>>>
>>>>>> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>>>>>>
>>>>>> </plugin>
>>>>>> <local/>
>>>>>> <complete/>
>>>>>> </metamodels>
>>>>>> <woven id="0">
>>>>>> <model-relative-path>null</model-relative-path>
>>>>>> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>>>>>>
>>>>>> <reference>leftM</reference>
>>>>>> <title>leftM</title>
>>>>>> <panel>DefaultWovenPanelExtension</panel>
>>>>>> <wmodelref>ModelRef</wmodelref>
>>>>>> </woven>
>>>>>> <woven id="1">
>>>>>> <model-relative-path>null</model-relative-path>
>>>>>> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>>>>>>
>>>>>> <reference>rightM</reference>
>>>>>> <title>rightM</title>
>>>>>> <panel>DefaultWovenPanelExtension</panel>
>>>>>> <wmodelref>ModelRef</wmodelref>
>>>>>> </woven>
>>>>>> </weaver>
>>>>>>
>>>>>> I load the metamodels in the wizard from other project, do you
>>>>>> think this could create problems?.
>>>>>> I could try copying them into this one and see if that helps.
>>>>>> Regards, and thanks for your help.
>>>>>>
>>>>>>
>>>>>>
>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>> Hi,
>>>>>>>
>>>>>>> The problem is that it didn't find the right element (it returned
>>>>>>> a "null" in the getElementRef method. However, I cannot say why
>>>>>>> this is happening. Maybe there is a path problem or something
>>>>>>> related.
>>>>>>>
>>>>>>> Can you copy the value of the "rightM" and "leftM" elements, and
>>>>>>> an excerpt of the .prop.amw.file with the file paths?
>>>>>>>
>>>>>>> The "rightM" element looks like the following:
>>>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>>>>> ref="/<metamodelpath>.ecore">
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Marcos.
>>>>>>>
>>>>>>> Juan Pedro Silva wrote:
>>>>>>>> Hi Marcos, thanks for your quick answer.
>>>>>>>> Ok on the HOT, I'll work on it.
>>>>>>>> Regarding the matching operations, I was using the extensions
>>>>>>>> you enumerated, and no others. I was following the "Metamodel
>>>>>>>> comparison" use case verbatim with my own metamodels.
>>>>>>>> The input model for the "Name Equality" matching operation was
>>>>>>>> the output of the "cartesian product" operation. Validating this
>>>>>>>> model returns no error or warnings.
>>>>>>>>
>>>>>>>> I looked for the matching rule (in the "_cp.amw") model that
>>>>>>>> shows up in the error stack ("UIComboBox_EAnnotation"), and it
>>>>>>>> has a right element:
>>>>>>>>
>>>>>>>> <ownedElement xsi:type="ElementEqual"
>>>>>>>> name="UIComboBox_EAnnotation" similarity="0.0">
>>>>>>>> <left xsi:type="LeftElement" name="UIComboBox"
>>>>>>>> element="//@leftM/@ownedElementRef.18"/>
>>>>>>>> <right xsi:type="RightElement" name="EAnnotation"
>>>>>>>> element="//@rightM/@ownedElementRef.108"/>
>>>>>>>> </ownedElement>
>>>>>>>>
>>>>>>>> I even navigated throw the "_cp.amw" file (opening it with the
>>>>>>>> text editor) and found no rule that hadn't a right element (this
>>>>>>>> was not exhaustive, though, as there are 223214 lines in that
>>>>>>>> file).
>>>>>>>> Re-running the "Name Equality" operation throws the same error
>>>>>>>> but in a different rule each time.
>>>>>>>> Any ideas?, would size be an issue?. I ask this because it takes
>>>>>>>> quite some time (a couple of minutes) to open this file with the
>>>>>>>> AMW editor, for instance.
>>>>>>>> Regards,
>>>>>>>> Juan Pedro
>>>>>>>>
>>>>>>>>
>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>> Hello,
>>>>>>>>>
>>>>>>>>> The matching transformations, as well as the corresponding
>>>>>>>>> HOTs, are implemented based on specific extensions to the AMW
>>>>>>>>> core metamodel. If you want to use new extensions, the HOT must
>>>>>>>>> be extended to be able to support them.
>>>>>>>>>
>>>>>>>>> To execute the matching transformations of the plug-in, the
>>>>>>>>> following extensions are needed:
>>>>>>>>> - mw_base_ext
>>>>>>>>> - mmw_match (equality, cardinality, type and conformance,
>>>>>>>>> Cartesian product, link rewriting, threshold)
>>>>>>>>> - mm_propagation (SF, propagation graph)
>>>>>>>>> - mmw_compare (not equivalence)
>>>>>>>>>
>>>>>>>>> If you add new extensions, the transformations won't produce
>>>>>>>>> any additional result, since they are not aware of the
>>>>>>>>> existence of new types of links.
>>>>>>>>>
>>>>>>>>> Now, looking at your error log, it seems that you don't have
>>>>>>>>> any element associated to the "right" reference:
>>>>>>>>>
>>>>>>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>>>>>>
>>>>>>>>> The transformations need to have the "left" and "right"
>>>>>>>>> references set up in the weaving model.
>>>>>>>>>
>>>>>>>>> Regards,
>>>>>>>>>
>>>>>>>>> Marcos.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>> Hi Marcos, sorry for not being clear.
>>>>>>>>>> Your answer is of great help to manually generate the
>>>>>>>>>> transformations. I'm currently generating the weaving model
>>>>>>>>>> manually, but it will take some time to finish due to the size
>>>>>>>>>> (moderate, but not small) of the metamodels. After that I'll
>>>>>>>>>> give this a try.
>>>>>>>>>>
>>>>>>>>>> I was referring to the HOT (or "transfGen", as you call it in
>>>>>>>>>> your phd Thesis).
>>>>>>>>>> I'm having problems with the automatic generation of the
>>>>>>>>>> transformation, in various steps.
>>>>>>>>>> What I'm trying to do at this point (I postponed the
>>>>>>>>>> combination of models until I get this right) is:
>>>>>>>>>>
>>>>>>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>>>>>>> comparison use
>>>>>>>>>> case") for my own metamodels.
>>>>>>>>>> 2. Manually tune this model with some other wlink extensions
>>>>>>>>>> (previously loading my km3 extension).
>>>>>>>>>> 3. Generate the ATL transformation (HOT) by means of the
>>>>>>>>>> AMW context
>>>>>>>>>> menu option.
>>>>>>>>>>
>>>>>>>>>> However, I'm getting errors in step 1. I can execute the
>>>>>>>>>> "Metamodel Match -> Cartesian Product" (takes long but works),
>>>>>>>>>> but I get errors when running the "Name Equality" on the cp
>>>>>>>>>> result (I'm attaching the console output). I also get an error
>>>>>>>>>> while trying step 3 on a partial weaving model, but as the
>>>>>>>>>> weaving model was partial and manual, I'll wait until it is
>>>>>>>>>> complete and try again.
>>>>>>>>>>
>>>>>>>>>> The question would be, are there any conditions on the
>>>>>>>>>> metamodels in order for the matching to work?, and is the
>>>>>>>>>> available HOT general enough for using it with our own
>>>>>>>>>> weaving-metamodel extensions, or I am supposed to make my own
>>>>>>>>>> HOTs for them?.
>>>>>>>>>>
>>>>>>>>>> Thanks again, Marcos.
>>>>>>>>>> Regards,
>>>>>>>>>> Juan Pedro
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>>
>>>>>>>>>>> Hello,
>>>>>>>>>>>
>>>>>>>>>>> I didn't understand what you mean by "linking the rules with
>>>>>>>>>>> ATL".
>>>>>>>>>>>
>>>>>>>>>>> You can set the weaving model as input (or output) in the ATL
>>>>>>>>>>> transformation, and than use it in different ways. I depict
>>>>>>>>>>> some below:
>>>>>>>>>>>
>>>>>>>>>>> The signature of the transformation would be the following:
>>>>>>>>>>>
>>>>>>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>>>>>>
>>>>>>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>>>>>>
>>>>>>>>>>> rule MatchLink {
>>>>>>>>>>>
>>>>>>>>>>> from
>>>>>>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource
>>>>>>>>>>> (some condition to verify the correct input resource )
>>>>>>>>>>>
>>>>>>>>>>> to
>>>>>>>>>>> out : MMB!Resource (
>>>>>>>>>>> action <- -- check for the target resource actions
>>>>>>>>>>> -- see the AMW model handler Wiki
>>>>>>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to
>>>>>>>>>>> check how the getReffered() method works)
>>>>>>>>>>> )
>>>>>>>>>>>
>>>>>>>>>>> }
>>>>>>>>>>>
>>>>>>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>>>>>>> search for the linked elements.
>>>>>>>>>>>
>>>>>>>>>>> rule ActionsToResource {
>>>>>>>>>>> from
>>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>>> to
>>>>>>>>>>> out : MMB!Resource
>>>>>>>>>>> (
>>>>>>>>>>> action <- cO.getOutputActions() -- The helper
>>>>>>>>>>> is created for better readability.
>>>>>>>>>>> )
>>>>>>>>>>> }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>>>>>>> (MMA!Action) =
>>>>>>>>>>> -- the helper should search for the ResourceCombination
>>>>>>>>>>> links and that returns the model elements based on the values
>>>>>>>>>>> of the references targetResource and createAction.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Regards,
>>>>>>>>>>>
>>>>>>>>>>> Marcos.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>>> Marcos, I'm back to this after some time doing some other
>>>>>>>>>>>> stuff.
>>>>>>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>>>>>>> transformation with the definition of the weaving metamodel
>>>>>>>>>>>> extensions.
>>>>>>>>>>>>
>>>>>>>>>>>> For example, I define the following extension (I based it on
>>>>>>>>>>>> the AOM use case):
>>>>>>>>>>>>
>>>>>>>>>>>> class ResourceCombination extends WLink {
>>>>>>>>>>>> -- @subsets end
>>>>>>>>>>>> reference targetResource [*] container : Resource;
>>>>>>>>>>>> -- @subsets end
>>>>>>>>>>>> reference createActions [*] container : Resource;
>>>>>>>>>>>> }
>>>>>>>>>>>> class Resource extends WLinkEnd {
>>>>>>>>>>>> }
>>>>>>>>>>>>
>>>>>>>>>>>> and now I want to express that, when I draw a
>>>>>>>>>>>> "ResourceCombination" link, every action that exists on the
>>>>>>>>>>>> "createActions" Resource should be created in the
>>>>>>>>>>>> "targetResource" Resource (I want to do more complicated
>>>>>>>>>>>> things with it, but lets start with this).
>>>>>>>>>>>> In atl, such rule would be:
>>>>>>>>>>>>
>>>>>>>>>>>> rule ActionsToResource
>>>>>>>>>>>> --My guess is that the rule name doesn't affect
>>>>>>>>>>>> {
>>>>>>>>>>>> from
>>>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>>>> to
>>>>>>>>>>>> out : MMB!Resource
>>>>>>>>>>>> (
>>>>>>>>>>>> action <- cO.action
>>>>>>>>>>>> --where "action" is a set of "Action"
>>>>>>>>>>>> elements )
>>>>>>>>>>>> }
>>>>>>>>>>>>
>>>>>>>>>>>> What I don't know how to do is to associate the weaving
>>>>>>>>>>>> model (.amw) with the transformation rules (.atl), in order
>>>>>>>>>>>> to apply the weavings.
>>>>>>>>>>>> How does the linking of the amw extensions with the rules
>>>>>>>>>>>> takes place?.
>>>>>>>>>>>> Thank you very much.
>>>>>>>>>>>> Regards,
>>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>>>> Hello,
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> In aspect oriented modeling, the metamodels are combined.
>>>>>>>>>>>>> It would be the creation of MMA + SecureUML metamodel based
>>>>>>>>>>>>> on links between MMA and SecureUML.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Your case seems more similar to the "Merge of geographical
>>>>>>>>>>>>> data" use case.
>>>>>>>>>>>>> http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>>>>>>
>>>>>>>>>>>>> This is a complex case, where the generated transformation
>>>>>>>>>>>>> must take two models as input and produce one model as
>>>>>>>>>>>>> output. You need a special extension of AMW to support this
>>>>>>>>>>>>> kind of scenario. Take a look on this use case to see if
>>>>>>>>>>>>> you can get some inspiration. :) Let me know if you have
>>>>>>>>>>>>> any other questions.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Regards,
>>>>>>>>>>>>>
>>>>>>>>>>>>> Marcos.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>>>>>>> I'm trying to use AMW for the first time, and I believe I
>>>>>>>>>>>>>> could use some help from people with more knowledge of it
>>>>>>>>>>>>>> than me.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1'
>>>>>>>>>>>>>> corresponding to Meta-Model "A" (something like a simpler
>>>>>>>>>>>>>> version of UML), and a second model "IN2", that is a
>>>>>>>>>>>>>> security model that corresponds to SecureUML metamodel. I
>>>>>>>>>>>>>> wanted to combine this two models into a target model that
>>>>>>>>>>>>>> corresponds to a metamodel that is the result of the
>>>>>>>>>>>>>> merging of the first two (see the attached picture). This
>>>>>>>>>>>>>> "combination" of the models is more than a mere merging.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> How could I do this?. In the use cases I saw from the
>>>>>>>>>>>>>> website there is always one input model and some matching
>>>>>>>>>>>>>> rules to generate one output model (sort of as in a simple
>>>>>>>>>>>>>> ATL transformation).
>>>>>>>>>>>>>> I tried using the wizard declaring two input models (IN1
>>>>>>>>>>>>>> and IN2) and the output metamodel, but when it comes to
>>>>>>>>>>>>>> choosing the input, I can only choose one element from
>>>>>>>>>>>>>> either one of the input models.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> I believe I'm missing the big picture here, and I surely
>>>>>>>>>>>>>> need some advice to get going.
>>>>>>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>>>>>>> Regards,
>>>>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
Re: Model combination. [message #469569 is a reply to message #469567] Mon, 02 February 2009 06:47 Go to previous message
Juan Pedro Silva is currently offline Juan Pedro Silva
Messages: 258
Registered: July 2009
Senior Member
Thanks for everything, Marcos.
I'll work on the HOT for my resource combination and include
enumerations in it.
Best regards,
Juan Pedro

Marcos Didonet Del Fabro escribió:
> Hello,
>
> The matching transformations do not create links between enumerations.
> We didn't implement the support to enumerations in the HOT. The HOT
> has a rule that matches "ElementEqual" links, and it expects that they
> connect two classes, so it tests the "abstract" property. That's why
> it does not work.
>
> You can create a different kind of link, though the current HOT won't
> produce any extra result (but there will be no errors). You can, of
> course, improve the HOT implementation to handle enumerations.
>
>
> Regards,
>
> Marcos.
>
> Juan Pedro Silva wrote:
>> Marcos, you were right: deleting the EAnnotation elements made it
>> work. Thanks.
>> I have one more question, regarding enumerations. I see enumerations
>> are not being matched. If I match them manually (using "Element
>> Equal" for enums and "Attribute Equal" for literals), the HOT
>> generation throws an error (feature abstract does not exist in
>> MOF!EEnum).
>>
>> I don't know if this is the same issue as with EAnnotations, being
>> Enumeration a MOF element and all.
>> Perhaps I should use another type of link (instead of "Element
>> Equal"), one that the HOT doesn't check for the elements to be
>> abstract. Any suggestions?.
>>
>> Best regards and thank you very much for all your help,
>>
>> Juan Pedro
>>
>>
>>
>> Marcos Didonet Del Fabro escribió:
>>> Hello,
>>>
>>> I think I know the problem. One of the metamodels (right) refers to
>>> some elements from Ecore, for instance, datatypes such as EString,
>>> EBoolean, EInteger.
>>>
>>> In this case, the EMF model handler resolves this reference, and it
>>> "includes" all Ecore into the metamodel, so the matching
>>> transformation will also match elements such as EAnnotation, EClass,
>>> EStructuralFeature, etc.
>>> These references should be deleted to be able to correctly execute
>>> the matching transformations.
>>>
>>> When creating "clean" metamodels, this practice should be avoided.
>>> In the case of data types, the better solution is to create a
>>> package "DataTypes" and create the corresponding data types (String,
>>> Double, etc). This is how we proceed when creating KM3 or Ecore
>>> metamodels. You can find examples int the ATL or AMW use cases page.
>>>
>>> Regards,
>>>
>>> Marcos.
>>>
>>> Juan Pedro Silva wrote:
>>>> You mean the EAnnotation element from the Ecore metamodel?.
>>>> There is no "EAnnotation" element in my metamodels (input or
>>>> output). There are some comments, however, in the input metamodel
>>>> which are expressed as:
>>>>
>>>> <eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
>>>> <details key="documentation" value="Some documentation text"/>
>>>> </eAnnotations>
>>>>
>>>> I see there are mapping rules in the "Cartesian Product" result
>>>> with right elements EAnnotation (I believe it's allways the right
>>>> element), but such a metaclass/element doesn't exist in the target
>>>> metamodel (I opened it in a text editor and searched for the
>>>> "EAnnotation" with no results), nor does the previously described
>>>> comments.
>>>> Hope this helps.
>>>>
>>>> Marcos Didonet Del Fabro escribió:
>>>>>
>>>>> It seems something related with the EAnnotation element. Can you
>>>>> explain what is it about?
>>>>>
>>>>> Marcos.
>>>>>
>>>>> Juan Pedro Silva wrote:
>>>>>> Making a new model weaverwith the metamodels in the root folder
>>>>>> of the same project has the same results as in the previous one,
>>>>>> regretfully.
>>>>>>
>>>>>> Juan Pedro Silva escribió:
>>>>>>> Marcos:
>>>>>>>
>>>>>>> <leftM xsi:type="_1:ModelRef" xmi:id="ModelRef1" name="leftM"
>>>>>>> ref="/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore ">
>>>>>>>
>>>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2" name="rightM"
>>>>>>> ref=" /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore ">
>>>>>>>
>>>>>>>
>>>>>>> And the .prop.amw file:
>>>>>>>
>>>>>>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>>>>>>> <weaver>
>>>>>>> <weaving>
>>>>>>> <relative-path>/iBuilderMatching/iBuilderMatching.amw</relative-path >
>>>>>>>
>>>>>>> <panel>TransformationWeavingPanelExtension</panel>
>>>>>>> <wmodel>MatchModel</wmodel>
>>>>>>> </weaving>
>>>>>>> <metamodels>
>>>>>>> <plugin>
>>>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_match. km3 </relative-path>
>>>>>>>
>>>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_propag ation.km3 </relative-path>
>>>>>>>
>>>>>>> <relative-path> org.eclipse.gmt.weaver.matchextensions/metamodels/mmw_compar e.km3 </relative-path>
>>>>>>>
>>>>>>> <relative-path> org.eclipse.weaver.extension.base/metamodels/mw_base_extensi on.km3 </relative-path>
>>>>>>>
>>>>>>> </plugin>
>>>>>>> <local/>
>>>>>>> <complete/>
>>>>>>> </metamodels>
>>>>>>> <woven id="0">
>>>>>>> <model-relative-path>null</model-relative-path>
>>>>>>> <metamodel-relative-path>/iBuilderSecureUMLComposition/metamodels/iBuilderMM.ecore </metamodel-relative-path>
>>>>>>>
>>>>>>> <reference>leftM</reference>
>>>>>>> <title>leftM</title>
>>>>>>> <panel>DefaultWovenPanelExtension</panel>
>>>>>>> <wmodelref>ModelRef</wmodelref>
>>>>>>> </woven>
>>>>>>> <woven id="1">
>>>>>>> <model-relative-path>null</model-relative-path>
>>>>>>> <metamodel-relative-path> /iBuilderSecureUMLComposition/metamodels/iBuilder_plus_Secur eUML_Flat_MM.ecore </metamodel-relative-path>
>>>>>>>
>>>>>>> <reference>rightM</reference>
>>>>>>> <title>rightM</title>
>>>>>>> <panel>DefaultWovenPanelExtension</panel>
>>>>>>> <wmodelref>ModelRef</wmodelref>
>>>>>>> </woven>
>>>>>>> </weaver>
>>>>>>>
>>>>>>> I load the metamodels in the wizard from other project, do you
>>>>>>> think this could create problems?.
>>>>>>> I could try copying them into this one and see if that helps.
>>>>>>> Regards, and thanks for your help.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> The problem is that it didn't find the right element (it
>>>>>>>> returned a "null" in the getElementRef method. However, I
>>>>>>>> cannot say why this is happening. Maybe there is a path problem
>>>>>>>> or something related.
>>>>>>>>
>>>>>>>> Can you copy the value of the "rightM" and "leftM" elements,
>>>>>>>> and an excerpt of the .prop.amw.file with the file paths?
>>>>>>>>
>>>>>>>> The "rightM" element looks like the following:
>>>>>>>> <rightM xsi:type="_1:ModelRef" xmi:id="ModelRef2"
>>>>>>>> name="rightM" ref="/<metamodelpath>.ecore">
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Marcos.
>>>>>>>>
>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>> Hi Marcos, thanks for your quick answer.
>>>>>>>>> Ok on the HOT, I'll work on it.
>>>>>>>>> Regarding the matching operations, I was using the extensions
>>>>>>>>> you enumerated, and no others. I was following the "Metamodel
>>>>>>>>> comparison" use case verbatim with my own metamodels.
>>>>>>>>> The input model for the "Name Equality" matching operation was
>>>>>>>>> the output of the "cartesian product" operation. Validating
>>>>>>>>> this model returns no error or warnings.
>>>>>>>>>
>>>>>>>>> I looked for the matching rule (in the "_cp.amw") model that
>>>>>>>>> shows up in the error stack ("UIComboBox_EAnnotation"), and it
>>>>>>>>> has a right element:
>>>>>>>>>
>>>>>>>>> <ownedElement xsi:type="ElementEqual"
>>>>>>>>> name="UIComboBox_EAnnotation" similarity="0.0">
>>>>>>>>> <left xsi:type="LeftElement" name="UIComboBox"
>>>>>>>>> element="//@leftM/@ownedElementRef.18"/>
>>>>>>>>> <right xsi:type="RightElement" name="EAnnotation"
>>>>>>>>> element="//@rightM/@ownedElementRef.108"/>
>>>>>>>>> </ownedElement>
>>>>>>>>>
>>>>>>>>> I even navigated throw the "_cp.amw" file (opening it with the
>>>>>>>>> text editor) and found no rule that hadn't a right element
>>>>>>>>> (this was not exhaustive, though, as there are 223214 lines in
>>>>>>>>> that file).
>>>>>>>>> Re-running the "Name Equality" operation throws the same error
>>>>>>>>> but in a different rule each time.
>>>>>>>>> Any ideas?, would size be an issue?. I ask this because it
>>>>>>>>> takes quite some time (a couple of minutes) to open this file
>>>>>>>>> with the AMW editor, for instance.
>>>>>>>>> Regards,
>>>>>>>>> Juan Pedro
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>> Hello,
>>>>>>>>>>
>>>>>>>>>> The matching transformations, as well as the corresponding
>>>>>>>>>> HOTs, are implemented based on specific extensions to the AMW
>>>>>>>>>> core metamodel. If you want to use new extensions, the HOT
>>>>>>>>>> must be extended to be able to support them.
>>>>>>>>>>
>>>>>>>>>> To execute the matching transformations of the plug-in, the
>>>>>>>>>> following extensions are needed:
>>>>>>>>>> - mw_base_ext
>>>>>>>>>> - mmw_match (equality, cardinality, type and conformance,
>>>>>>>>>> Cartesian product, link rewriting, threshold)
>>>>>>>>>> - mm_propagation (SF, propagation graph)
>>>>>>>>>> - mmw_compare (not equivalence)
>>>>>>>>>>
>>>>>>>>>> If you add new extensions, the transformations won't produce
>>>>>>>>>> any additional result, since they are not aware of the
>>>>>>>>>> existence of new types of links.
>>>>>>>>>>
>>>>>>>>>> Now, looking at your error log, it seems that you don't have
>>>>>>>>>> any element associated to the "right" reference:
>>>>>>>>>>
>>>>>>>>>> variables = {left = left!UIComboBox}}, 'right']
>>>>>>>>>>
>>>>>>>>>> The transformations need to have the "left" and "right"
>>>>>>>>>> references set up in the weaving model.
>>>>>>>>>>
>>>>>>>>>> Regards,
>>>>>>>>>>
>>>>>>>>>> Marcos.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>> Hi Marcos, sorry for not being clear.
>>>>>>>>>>> Your answer is of great help to manually generate the
>>>>>>>>>>> transformations. I'm currently generating the weaving model
>>>>>>>>>>> manually, but it will take some time to finish due to the
>>>>>>>>>>> size (moderate, but not small) of the metamodels. After that
>>>>>>>>>>> I'll give this a try.
>>>>>>>>>>>
>>>>>>>>>>> I was referring to the HOT (or "transfGen", as you call it
>>>>>>>>>>> in your phd Thesis).
>>>>>>>>>>> I'm having problems with the automatic generation of the
>>>>>>>>>>> transformation, in various steps.
>>>>>>>>>>> What I'm trying to do at this point (I postponed the
>>>>>>>>>>> combination of models until I get this right) is:
>>>>>>>>>>>
>>>>>>>>>>> 1. An automatic Matching model (as in the "Metamodel
>>>>>>>>>>> comparison use
>>>>>>>>>>> case") for my own metamodels.
>>>>>>>>>>> 2. Manually tune this model with some other wlink extensions
>>>>>>>>>>> (previously loading my km3 extension).
>>>>>>>>>>> 3. Generate the ATL transformation (HOT) by means of the
>>>>>>>>>>> AMW context
>>>>>>>>>>> menu option.
>>>>>>>>>>>
>>>>>>>>>>> However, I'm getting errors in step 1. I can execute the
>>>>>>>>>>> "Metamodel Match -> Cartesian Product" (takes long but
>>>>>>>>>>> works), but I get errors when running the "Name Equality" on
>>>>>>>>>>> the cp result (I'm attaching the console output). I also get
>>>>>>>>>>> an error while trying step 3 on a partial weaving model, but
>>>>>>>>>>> as the weaving model was partial and manual, I'll wait until
>>>>>>>>>>> it is complete and try again.
>>>>>>>>>>>
>>>>>>>>>>> The question would be, are there any conditions on the
>>>>>>>>>>> metamodels in order for the matching to work?, and is the
>>>>>>>>>>> available HOT general enough for using it with our own
>>>>>>>>>>> weaving-metamodel extensions, or I am supposed to make my
>>>>>>>>>>> own HOTs for them?.
>>>>>>>>>>>
>>>>>>>>>>> Thanks again, Marcos.
>>>>>>>>>>> Regards,
>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>>>
>>>>>>>>>>>> Hello,
>>>>>>>>>>>>
>>>>>>>>>>>> I didn't understand what you mean by "linking the rules
>>>>>>>>>>>> with ATL".
>>>>>>>>>>>>
>>>>>>>>>>>> You can set the weaving model as input (or output) in the
>>>>>>>>>>>> ATL transformation, and than use it in different ways. I
>>>>>>>>>>>> depict some below:
>>>>>>>>>>>>
>>>>>>>>>>>> The signature of the transformation would be the following:
>>>>>>>>>>>>
>>>>>>>>>>>> module MyModule create OUT : MMB from IN : MMA, IN2 : AMW;
>>>>>>>>>>>>
>>>>>>>>>>>> 1) Matching the weaving link + the target actions:
>>>>>>>>>>>>
>>>>>>>>>>>> rule MatchLink {
>>>>>>>>>>>>
>>>>>>>>>>>> from
>>>>>>>>>>>> link : AMW!ResourceCombination, resource : MMA!Resource
>>>>>>>>>>>> (some condition to verify the correct input resource )
>>>>>>>>>>>>
>>>>>>>>>>>> to
>>>>>>>>>>>> out : MMB!Resource (
>>>>>>>>>>>> action <- -- check for the target resource actions
>>>>>>>>>>>> -- see the AMW model handler Wiki
>>>>>>>>>>>> (http://wiki.eclipse.org/index.php/AMW_Model_Handler) to
>>>>>>>>>>>> check how the getReffered() method works)
>>>>>>>>>>>> )
>>>>>>>>>>>>
>>>>>>>>>>>> }
>>>>>>>>>>>>
>>>>>>>>>>>> 2) you can create the rule similar as the one you have, and
>>>>>>>>>>>> search for the linked elements.
>>>>>>>>>>>>
>>>>>>>>>>>> rule ActionsToResource {
>>>>>>>>>>>> from
>>>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>>>> to
>>>>>>>>>>>> out : MMB!Resource
>>>>>>>>>>>> (
>>>>>>>>>>>> action <- cO.getOutputActions() -- The helper
>>>>>>>>>>>> is created for better readability.
>>>>>>>>>>>> )
>>>>>>>>>>>> }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> helper context MMA!Resource getOutputActions() : Sequence
>>>>>>>>>>>> (MMA!Action) =
>>>>>>>>>>>> -- the helper should search for the ResourceCombination
>>>>>>>>>>>> links and that returns the model elements based on the
>>>>>>>>>>>> values of the references targetResource and createAction.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Regards,
>>>>>>>>>>>>
>>>>>>>>>>>> Marcos.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>>>> Marcos, I'm back to this after some time doing some other
>>>>>>>>>>>>> stuff.
>>>>>>>>>>>>> I have a doubt regarding how to link the semantics of the
>>>>>>>>>>>>> transformation with the definition of the weaving
>>>>>>>>>>>>> metamodel extensions.
>>>>>>>>>>>>>
>>>>>>>>>>>>> For example, I define the following extension (I based it
>>>>>>>>>>>>> on the AOM use case):
>>>>>>>>>>>>>
>>>>>>>>>>>>> class ResourceCombination extends WLink {
>>>>>>>>>>>>> -- @subsets end
>>>>>>>>>>>>> reference targetResource [*] container : Resource;
>>>>>>>>>>>>> -- @subsets end
>>>>>>>>>>>>> reference createActions [*] container : Resource;
>>>>>>>>>>>>> }
>>>>>>>>>>>>> class Resource extends WLinkEnd {
>>>>>>>>>>>>> }
>>>>>>>>>>>>>
>>>>>>>>>>>>> and now I want to express that, when I draw a
>>>>>>>>>>>>> "ResourceCombination" link, every action that exists on
>>>>>>>>>>>>> the "createActions" Resource should be created in the
>>>>>>>>>>>>> "targetResource" Resource (I want to do more complicated
>>>>>>>>>>>>> things with it, but lets start with this).
>>>>>>>>>>>>> In atl, such rule would be:
>>>>>>>>>>>>>
>>>>>>>>>>>>> rule
>>>>>>>>>>>>> ActionsToResource
>>>>>>>>>>>>> --My guess is that the rule name doesn't affect
>>>>>>>>>>>>> {
>>>>>>>>>>>>> from
>>>>>>>>>>>>> cO : MMA!Resource
>>>>>>>>>>>>> to
>>>>>>>>>>>>> out : MMB!Resource
>>>>>>>>>>>>> (
>>>>>>>>>>>>> action <-
>>>>>>>>>>>>> cO.action --where "action" is a set of
>>>>>>>>>>>>> "Action" elements )
>>>>>>>>>>>>> }
>>>>>>>>>>>>>
>>>>>>>>>>>>> What I don't know how to do is to associate the weaving
>>>>>>>>>>>>> model (.amw) with the transformation rules (.atl), in
>>>>>>>>>>>>> order to apply the weavings.
>>>>>>>>>>>>> How does the linking of the amw extensions with the rules
>>>>>>>>>>>>> takes place?.
>>>>>>>>>>>>> Thank you very much.
>>>>>>>>>>>>> Regards,
>>>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Marcos Didonet Del Fabro escribió:
>>>>>>>>>>>>>> Hello,
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> In aspect oriented modeling, the metamodels are combined.
>>>>>>>>>>>>>> It would be the creation of MMA + SecureUML metamodel
>>>>>>>>>>>>>> based on links between MMA and SecureUML.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Your case seems more similar to the "Merge of
>>>>>>>>>>>>>> geographical data" use case.
>>>>>>>>>>>>>> http://www.eclipse.org/gmt/amw/usecases/mergeSVG/.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> This is a complex case, where the generated
>>>>>>>>>>>>>> transformation must take two models as input and produce
>>>>>>>>>>>>>> one model as output. You need a special extension of AMW
>>>>>>>>>>>>>> to support this kind of scenario. Take a look on this use
>>>>>>>>>>>>>> case to see if you can get some inspiration. :) Let me
>>>>>>>>>>>>>> know if you have any other questions.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Regards,
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Marcos.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Juan Pedro Silva wrote:
>>>>>>>>>>>>>>> Hi Marcos and everybody.
>>>>>>>>>>>>>>> I'm trying to use AMW for the first time, and I believe
>>>>>>>>>>>>>>> I could use some help from people with more knowledge of
>>>>>>>>>>>>>>> it than me.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> I would like to use AMW to combine models (in a sort of
>>>>>>>>>>>>>>> Aspect-Oriented Modeling). I have a Model 'IN1'
>>>>>>>>>>>>>>> corresponding to Meta-Model "A" (something like a
>>>>>>>>>>>>>>> simpler version of UML), and a second model "IN2", that
>>>>>>>>>>>>>>> is a security model that corresponds to SecureUML
>>>>>>>>>>>>>>> metamodel. I wanted to combine this two models into a
>>>>>>>>>>>>>>> target model that corresponds to a metamodel that is the
>>>>>>>>>>>>>>> result of the merging of the first two (see the attached
>>>>>>>>>>>>>>> picture). This "combination" of the models is more than
>>>>>>>>>>>>>>> a mere merging.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> How could I do this?. In the use cases I saw from the
>>>>>>>>>>>>>>> website there is always one input model and some
>>>>>>>>>>>>>>> matching rules to generate one output model (sort of as
>>>>>>>>>>>>>>> in a simple ATL transformation).
>>>>>>>>>>>>>>> I tried using the wizard declaring two input models (IN1
>>>>>>>>>>>>>>> and IN2) and the output metamodel, but when it comes to
>>>>>>>>>>>>>>> choosing the input, I can only choose one element from
>>>>>>>>>>>>>>> either one of the input models.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> I believe I'm missing the big picture here, and I surely
>>>>>>>>>>>>>>> need some advice to get going.
>>>>>>>>>>>>>>> Any help will be greatly appreciated.
>>>>>>>>>>>>>>> Regards,
>>>>>>>>>>>>>>> Juan Pedro
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ------------------------------------------------------------ ------------
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
Previous Topic:Class WlinkEnd - Error
Next Topic:WAssociation/WAssociationEnd concepts
Goto Forum:
  


Current Time: Fri Aug 22 19:44:58 EDT 2014

Powered by FUDForum. Page generated in 0.04155 seconds