Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » QVT-OML » [QVTo] UML 2 UML transform
[QVTo] UML 2 UML transform [message #870050] Sun, 06 May 2012 03:14 Go to next message
Alain Lavoie is currently offline Alain LavoieFriend
Messages: 82
Registered: April 2012
Member
Hello,

I followed with success a tutorial with QVTo. But my objectives is UML
to UML transformation with UML Profiles. I saw previous messages on
Profiles, so I will get there eventually and get back to these.

Meanwhile, the tutorial I used is transforming models produces with
Ecore files From observation of a Papyrus XMI file, the models looks
similar, but I am blocking on a first issues and I cannot find the
solution in the past M2M messages. By the way, Google has a hard time
with the eclipse forum references, I can rely on the Google cache, but
is this a temporary problem ?

Back to my issue, I have

modeltype umlMM uses 'http://www.eclipse.org/uml2/3.0.0/UML';


transformation CIMTransformation(in umlIn : umlMM, out umlOut : umlMM);

main() {
-- umlIn.rootObjects()[umlIn::Package] -> map ...
}


Q1 - Going to [Operational QVT Project] > [Properties] > [QVT Settings]
> [Metamodel mappings], I cannot find the way of adding a local
reference to the uml metamodel. How can I ?

Q2 - I guess this problem is related to Q1. I do not get Completion in
(Ctrl-space) the transformation file ?

Q3 - Will I have to convert in some way the uml model file (produced
with Papyrus) with a conform ecore file, or it is a valid ecore
file ?

I can read the model with the sample Ecore editor, but I do not
want to assume it is valid.

Regards.
Re: [QVTo] UML 2 UML transform [message #870077 is a reply to message #870050] Sun, 06 May 2012 08:02 Go to previous messageGo to next message
Tex Iano is currently offline Tex IanoFriend
Messages: 99
Registered: February 2012
Member
Hi Alain,

the metamodel has to be registered. So install the UML2 package for eclipse. You do not need to add a metamodel mapping. Then you have code completion.

Regards,

Tex
Re: [QVTo] UML 2 UML transform [message #870115 is a reply to message #870077] Sun, 06 May 2012 17:02 Go to previous messageGo to next message
Alain Lavoie is currently offline Alain LavoieFriend
Messages: 82
Registered: April 2012
Member
Hi Tex Iano
>
> the metamodel has to be registered.
Hm, I must be in the wrong menu settings...
Can you indicate me a page from the web, where I can follow
the procedure to do so, or the menu you are talking about ?
Are you refering to the menu listed in my question Q1 ?
Every attempts to insert different flavor of platform:...
failed. What kind of entries should I insert in the
Metamodel mappings source and target uri fields ?

> So install the UML2 package for
I presume it is already there, since I have Papyrus (UML Modeler)
and QVTo installed. I did though, since you mentionned it installed
the 2 following packages:
+ EMF Compare UML2 Integration
+ UML2 Extender SDK
From Help>Install new software, I cannot find anything else related to
UML2. From the Eclipse Plug-ins list, I seem to have all UML2 related
software, UML2 Model Search Ui, UML2 UML Editor, ...

Still, cannot have any completion (and this indicate me I did not
configured my project correctly) !

Any other hints ?

Thanks in advance.
Re: [QVTo] UML 2 UML transform [message #870119 is a reply to message #870077] Sun, 06 May 2012 17:26 Go to previous messageGo to next message
Alain Lavoie is currently offline Alain LavoieFriend
Messages: 82
Registered: April 2012
Member
Hello again Tex,

Now from your previous post, I have the following snippet:

modeltype uml "strict" uses uml('http://www.eclipse.org/uml2/3.0.0/UML');

transformation CIMTransformation(in umlIn : uml, out umlOut : uml);

main() {
umlIn.rootObjects()[umlIn::Package] -> map PackageToPackage();
}

Now I have the code completion for the umlIn::... but, should
I get a code completion for the qvt transformation fonctions like
PackageToPackage() ?

Thanks
Re: [QVTo] UML 2 UML transform [message #870147 is a reply to message #870119] Mon, 07 May 2012 03:53 Go to previous messageGo to next message
Alain Lavoie is currently offline Alain LavoieFriend
Messages: 82
Registered: April 2012
Member
Alain Lavoie a écrit :
> Hello again Tex,
>
> Now from your previous post, I have the following snippet:
>
> modeltype uml "strict" uses uml('http://www.eclipse.org/uml2/3.0.0/UML');
>
> transformation CIMTransformation(in umlIn : uml, out umlOut : uml);
>
> main() {
> umlIn.rootObjects()[umlIn::Package] -> map PackageToPackage();
> }
>
> Now I have the code completion for the umlIn::... but, should
> I get a code completion for the qvt transformation fonctions like
> PackageToPackage() ?
>
> Thanks
>
As an add-on to this discussion, from the wiki.eclipse.org/MDT/OCL/FAQ,
I get that ecore is a standalone metamodel that can define itself, and
that ecore can be used to express a UML metamodel. Furthermore, it
seems that UML is already delivered with QVTo. Hm... I still do not get
where the java PackageToPackage method is being defined. I verified
that that ecore::EPackage exist, both should use this definition for
my uml to uml transformation ?
Therefore, what is the equivalent PackageToPackage() in the ecore world ?

Finally, if I rely on ecore mm, I can imagine that I will miss some uml
concepts along the way, that those defined in uml but not in ecore.

Am I right ?

Regards.
Re: [QVTo] UML 2 UML transform [message #870159 is a reply to message #870147] Mon, 07 May 2012 05:28 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7127
Registered: July 2009
Senior Member
Hi

Your multiple messages seem to be getting increasingly confused.

I suggest a little more thought before pressing the send button,
otherwise I may start treating your messages as spam.

PackageToPackage is of course a mapping between two classes, so if you
use some other metamodel the parameter types will change.

Ecore corresponds to EMOF which is a simplified form of UML. If you
don't like the simplifications don't simplify.

An EMF mapping might be called EPackageToEPackage.

Regards

Ed Willink

On 07/05/2012 04:53, Alain Lavoie wrote:
> Alain Lavoie a écrit :
>> Hello again Tex,
>>
>> Now from your previous post, I have the following snippet:
>>
>> modeltype uml "strict" uses
>> uml('http://www.eclipse.org/uml2/3.0.0/UML');
>>
>> transformation CIMTransformation(in umlIn : uml, out umlOut : uml);
>>
>> main() {
>> umlIn.rootObjects()[umlIn::Package] -> map PackageToPackage();
>> }
>>
>> Now I have the code completion for the umlIn::... but, should
>> I get a code completion for the qvt transformation fonctions like
>> PackageToPackage() ?
>>
>> Thanks
>>
> As an add-on to this discussion, from the wiki.eclipse.org/MDT/OCL/FAQ,
> I get that ecore is a standalone metamodel that can define itself, and
> that ecore can be used to express a UML metamodel. Furthermore, it
> seems that UML is already delivered with QVTo. Hm... I still do not get
> where the java PackageToPackage method is being defined. I verified
> that that ecore::EPackage exist, both should use this definition for
> my uml to uml transformation ?
> Therefore, what is the equivalent PackageToPackage() in the ecore world ?
>
> Finally, if I rely on ecore mm, I can imagine that I will miss some uml
> concepts along the way, that those defined in uml but not in ecore.
>
> Am I right ?
>
> Regards.
Re: [QVTo] UML 2 UML transform [message #870255 is a reply to message #870159] Mon, 07 May 2012 13:22 Go to previous message
Alain Lavoie is currently offline Alain LavoieFriend
Messages: 82
Registered: April 2012
Member
Ed Willink a écrit :
> Hi
>
> Your multiple messages seem to be getting increasingly confused.
>
> I suggest a little more thought before pressing the send button,
> otherwise I may start treating your messages as spam.

Being alone on a project without any expertise around is a challenge.
I will respect your request.
Previous Topic:Code Completion / Operations in QVT installation
Next Topic:Failed to resolve metamodel when debugging
Goto Forum:
  


Current Time: Tue May 11 11:47:27 GMT 2021

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

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

Back to the top