Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » No UML2 Properties in UML-sourced GenModel
No UML2 Properties in UML-sourced GenModel [message #476987] Tue, 26 February 2008 19:20 Go to next message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi,

I am attempting to generate code from a UML model using the UML2 component's
codegen extensions. After I imported my GenModel from UML, I found that
the GenPackage doesn't have the UML2 properties (e.g., for the operations
package and resource interfaces) that I see in the UML.genmodel from the
org.eclipse.uml2.uml plug-in.

I notice that the UML.genmodel uses a specialized GenModel schema:

http://www.eclipse.org/uml2/1.1.0/GenModel

instead of the usual EMF GenModel:

http://www.eclipse.org/emf/2002/GenModel

which my genmodel references. I expect that this is related to the problem.

Is there anything I'm not doing, that I should be doing? I simply use the
UML importer in the New EMF Model wizard. I am using the UML2 SDK version
2.2.0 M5.

TIA,

Christian
Re: No UML2 Properties in UML-sourced GenModel [message #476994 is a reply to message #476987] Wed, 27 February 2008 13:53 Go to previous messageGo to next message
Kenn Hussey is currently offline Kenn HusseyFriend
Messages: 1620
Registered: July 2009
Senior Member
Christian,

The UML2 generator model is only used if certain options are specified in
the import wizard - basically options that need to be processed by UML2
because they can't be handled by EMF (e.g. the options for redefinitions,
subsets, derived unions, etc.). If you choose 'Process All', you'll get the
result you want, or perhaps you could turn on one of the UML-specific
options I just mentioned. I've been thinking for some time that the
interface needs to be improved so that the user can explicitly specify (e.g.
with a check box) that a UML2 generator model be used; if you open a
Bugzilla request, we'll take a look.

Kenn

"Christian W. Damus" <cdamus@ca.ibm.com> wrote in message
news:fq1oph$34k$1@build.eclipse.org...
> Hi,
>
> I am attempting to generate code from a UML model using the UML2
> component's
> codegen extensions. After I imported my GenModel from UML, I found that
> the GenPackage doesn't have the UML2 properties (e.g., for the operations
> package and resource interfaces) that I see in the UML.genmodel from the
> org.eclipse.uml2.uml plug-in.
>
> I notice that the UML.genmodel uses a specialized GenModel schema:
>
> http://www.eclipse.org/uml2/1.1.0/GenModel
>
> instead of the usual EMF GenModel:
>
> http://www.eclipse.org/emf/2002/GenModel
>
> which my genmodel references. I expect that this is related to the
> problem.
>
> Is there anything I'm not doing, that I should be doing? I simply use the
> UML importer in the New EMF Model wizard. I am using the UML2 SDK version
> 2.2.0 M5.
>
> TIA,
>
> Christian
Re: No UML2 Properties in UML-sourced GenModel [message #476997 is a reply to message #476994] Wed, 27 February 2008 14:29 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Thanks, Kenn,

Setting the options to process subsetted properties, etc., worked. I find
that some of the options' labels are a little misleading, though. For
example, it isn't clear that there should ever be any value in not
discarding duplicate operations. It there are duplicates, why retain them?
I had assumed that "duplicate" was different from "redefining" ...

Anyhow, say "Hello!" to https://bugs.eclipse.org/220552

As I indicated there, I think UML2 offers enough value-add to the code
generation to always employ its specialized GenModel.

cW


Kenn Hussey wrote:

> Christian,
>
> The UML2 generator model is only used if certain options are specified in
> the import wizard - basically options that need to be processed by UML2
> because they can't be handled by EMF (e.g. the options for redefinitions,
> subsets, derived unions, etc.). If you choose 'Process All', you'll get
> the result you want, or perhaps you could turn on one of the UML-specific
> options I just mentioned. I've been thinking for some time that the
> interface needs to be improved so that the user can explicitly specify
> (e.g. with a check box) that a UML2 generator model be used; if you open a
> Bugzilla request, we'll take a look.
>
> Kenn

-----8<-----
Re: No UML2 Properties in UML-sourced GenModel [message #476999 is a reply to message #476997] Wed, 27 February 2008 14:46 Go to previous message
Kenn Hussey is currently offline Kenn HusseyFriend
Messages: 1620
Registered: July 2009
Senior Member
Christian,

EMF discards "duplicates" by default. UML2 support "processing" them, which
means it will generate overrides that you can implement to do something
different in subclasses.

Thanks for the bug - I agree that it should always produce a UML2 generator
model (see my comment on the bug).

Kenn

"Christian W. Damus" <cdamus@ca.ibm.com> wrote in message
news:fq3s4q$5j1$1@build.eclipse.org...
> Thanks, Kenn,
>
> Setting the options to process subsetted properties, etc., worked. I find
> that some of the options' labels are a little misleading, though. For
> example, it isn't clear that there should ever be any value in not
> discarding duplicate operations. It there are duplicates, why retain
> them?
> I had assumed that "duplicate" was different from "redefining" ...
>
> Anyhow, say "Hello!" to https://bugs.eclipse.org/220552
>
> As I indicated there, I think UML2 offers enough value-add to the code
> generation to always employ its specialized GenModel.
>
> cW
>
>
> Kenn Hussey wrote:
>
>> Christian,
>>
>> The UML2 generator model is only used if certain options are specified in
>> the import wizard - basically options that need to be processed by UML2
>> because they can't be handled by EMF (e.g. the options for redefinitions,
>> subsets, derived unions, etc.). If you choose 'Process All', you'll get
>> the result you want, or perhaps you could turn on one of the UML-specific
>> options I just mentioned. I've been thinking for some time that the
>> interface needs to be improved so that the user can explicitly specify
>> (e.g. with a check box) that a UML2 generator model be used; if you open
>> a
>> Bugzilla request, we'll take a look.
>>
>> Kenn
>
> -----8<-----
Re: No UML2 Properties in UML-sourced GenModel [message #626097 is a reply to message #476987] Wed, 27 February 2008 13:53 Go to previous message
Kenn Hussey is currently offline Kenn HusseyFriend
Messages: 1620
Registered: July 2009
Senior Member
Christian,

The UML2 generator model is only used if certain options are specified in
the import wizard - basically options that need to be processed by UML2
because they can't be handled by EMF (e.g. the options for redefinitions,
subsets, derived unions, etc.). If you choose 'Process All', you'll get the
result you want, or perhaps you could turn on one of the UML-specific
options I just mentioned. I've been thinking for some time that the
interface needs to be improved so that the user can explicitly specify (e.g.
with a check box) that a UML2 generator model be used; if you open a
Bugzilla request, we'll take a look.

Kenn

"Christian W. Damus" <cdamus@ca.ibm.com> wrote in message
news:fq1oph$34k$1@build.eclipse.org...
> Hi,
>
> I am attempting to generate code from a UML model using the UML2
> component's
> codegen extensions. After I imported my GenModel from UML, I found that
> the GenPackage doesn't have the UML2 properties (e.g., for the operations
> package and resource interfaces) that I see in the UML.genmodel from the
> org.eclipse.uml2.uml plug-in.
>
> I notice that the UML.genmodel uses a specialized GenModel schema:
>
> http://www.eclipse.org/uml2/1.1.0/GenModel
>
> instead of the usual EMF GenModel:
>
> http://www.eclipse.org/emf/2002/GenModel
>
> which my genmodel references. I expect that this is related to the
> problem.
>
> Is there anything I'm not doing, that I should be doing? I simply use the
> UML importer in the New EMF Model wizard. I am using the UML2 SDK version
> 2.2.0 M5.
>
> TIA,
>
> Christian
Re: No UML2 Properties in UML-sourced GenModel [message #626100 is a reply to message #476994] Wed, 27 February 2008 14:29 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Thanks, Kenn,

Setting the options to process subsetted properties, etc., worked. I find
that some of the options' labels are a little misleading, though. For
example, it isn't clear that there should ever be any value in not
discarding duplicate operations. It there are duplicates, why retain them?
I had assumed that "duplicate" was different from "redefining" ...

Anyhow, say "Hello!" to https://bugs.eclipse.org/220552

As I indicated there, I think UML2 offers enough value-add to the code
generation to always employ its specialized GenModel.

cW


Kenn Hussey wrote:

> Christian,
>
> The UML2 generator model is only used if certain options are specified in
> the import wizard - basically options that need to be processed by UML2
> because they can't be handled by EMF (e.g. the options for redefinitions,
> subsets, derived unions, etc.). If you choose 'Process All', you'll get
> the result you want, or perhaps you could turn on one of the UML-specific
> options I just mentioned. I've been thinking for some time that the
> interface needs to be improved so that the user can explicitly specify
> (e.g. with a check box) that a UML2 generator model be used; if you open a
> Bugzilla request, we'll take a look.
>
> Kenn

-----8<-----
Re: No UML2 Properties in UML-sourced GenModel [message #626102 is a reply to message #476997] Wed, 27 February 2008 14:46 Go to previous message
Kenn Hussey is currently offline Kenn HusseyFriend
Messages: 1620
Registered: July 2009
Senior Member
Christian,

EMF discards "duplicates" by default. UML2 support "processing" them, which
means it will generate overrides that you can implement to do something
different in subclasses.

Thanks for the bug - I agree that it should always produce a UML2 generator
model (see my comment on the bug).

Kenn

"Christian W. Damus" <cdamus@ca.ibm.com> wrote in message
news:fq3s4q$5j1$1@build.eclipse.org...
> Thanks, Kenn,
>
> Setting the options to process subsetted properties, etc., worked. I find
> that some of the options' labels are a little misleading, though. For
> example, it isn't clear that there should ever be any value in not
> discarding duplicate operations. It there are duplicates, why retain
> them?
> I had assumed that "duplicate" was different from "redefining" ...
>
> Anyhow, say "Hello!" to https://bugs.eclipse.org/220552
>
> As I indicated there, I think UML2 offers enough value-add to the code
> generation to always employ its specialized GenModel.
>
> cW
>
>
> Kenn Hussey wrote:
>
>> Christian,
>>
>> The UML2 generator model is only used if certain options are specified in
>> the import wizard - basically options that need to be processed by UML2
>> because they can't be handled by EMF (e.g. the options for redefinitions,
>> subsets, derived unions, etc.). If you choose 'Process All', you'll get
>> the result you want, or perhaps you could turn on one of the UML-specific
>> options I just mentioned. I've been thinking for some time that the
>> interface needs to be improved so that the user can explicitly specify
>> (e.g. with a check box) that a UML2 generator model be used; if you open
>> a
>> Bugzilla request, we'll take a look.
>>
>> Kenn
>
> -----8<-----
Previous Topic:Importing XMI
Next Topic:ConvertToMetamodelAction makes classifiers private
Goto Forum:
  


Current Time: Wed Apr 24 17:24:55 GMT 2024

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

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

Back to the top