Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » translating java annotations to an UML repesentation
translating java annotations to an UML repesentation [message #477369] Fri, 09 May 2008 14:28 Go to next message
urs zeidler is currently offline urs zeidler
Messages: 91
Registered: July 2009
Member
While working with the topcased java2uml importer, I was thinking about
the translation of java annotations to UML elements.

After reading
www.st.informatik.tu-darmstadt.de/database/publications/data /cepa-kloppenburg-aom05.pdf?id=138
I think representing Java Annotations by Stereotypes is the best way to
go and it feels a kind of "natural". Stereotypes are grouped together in
a Profile, and for example "JSR 181"(Java Annotations for Webservice) is
such a kind of Profile.

Are there any other specifications or thought about it ?

greetings, urs.
Re: translating java annotations to an UML repesentation [message #477370 is a reply to message #477369] Fri, 09 May 2008 22:33 Go to previous messageGo to next message
Rafael Chaves is currently offline Rafael Chaves
Messages: 362
Registered: July 2009
Senior Member
Yes, Java annotations map naturally to UML stereotypes.

But unless you want to create a UML model that maps closely to the
implementation artifacts, you probably won't want to map *every*
annotation (or class, for that matter).

Cheers,

Rafael

urs zeidler wrote:
> While working with the topcased java2uml importer, I was thinking about
> the translation of java annotations to UML elements.
>
> After reading
> www.st.informatik.tu-darmstadt.de/database/publications/data /cepa-kloppenburg-aom05.pdf?id=138
>
> I think representing Java Annotations by Stereotypes is the best way to
> go and it feels a kind of "natural". Stereotypes are grouped together in
> a Profile, and for example "JSR 181"(Java Annotations for Webservice) is
> such a kind of Profile.
>
> Are there any other specifications or thought about it ?
>
> greetings, urs.
>
Re: translating java annotations to an UML repesentation [message #477372 is a reply to message #477370] Sat, 10 May 2008 06:24 Go to previous message
urs zeidler is currently offline urs zeidler
Messages: 16
Registered: July 2009
Junior Member
Rafael Chaves wrote:
> Yes, Java annotations map naturally to UML stereotypes.
That's what I feel too.
>
> But unless you want to create a UML model that maps closely to the
> implementation artifacts, you probably won't want to map *every*
> annotation (or class, for that matter).
Of course, @Override, or even better @SuspessWarnings don't carries much
semantic weight in the scope of the model. But as you will need to apply
a profile to the model, to apply stereotypes, only annotations mapping
to stereotypes defined by the applied profiles could be processed.
So the deeps of the mapping is controlled by the applied profiles. This
looks like a clean solution.

greetings, urs.
Re: translating java annotations to an UML repesentation [message #626549 is a reply to message #477369] Fri, 09 May 2008 22:33 Go to previous message
Rafael Chaves is currently offline Rafael Chaves
Messages: 362
Registered: July 2009
Senior Member
Yes, Java annotations map naturally to UML stereotypes.

But unless you want to create a UML model that maps closely to the
implementation artifacts, you probably won't want to map *every*
annotation (or class, for that matter).

Cheers,

Rafael

urs zeidler wrote:
> While working with the topcased java2uml importer, I was thinking about
> the translation of java annotations to UML elements.
>
> After reading
> www.st.informatik.tu-darmstadt.de/database/publications/data /cepa-kloppenburg-aom05.pdf?id=138
>
> I think representing Java Annotations by Stereotypes is the best way to
> go and it feels a kind of "natural". Stereotypes are grouped together in
> a Profile, and for example "JSR 181"(Java Annotations for Webservice) is
> such a kind of Profile.
>
> Are there any other specifications or thought about it ?
>
> greetings, urs.
>
Re: translating java annotations to an UML repesentation [message #626551 is a reply to message #477370] Sat, 10 May 2008 06:24 Go to previous message
urs zeidler is currently offline urs zeidler
Messages: 16
Registered: July 2009
Junior Member
Rafael Chaves wrote:
> Yes, Java annotations map naturally to UML stereotypes.
That's what I feel too.
>
> But unless you want to create a UML model that maps closely to the
> implementation artifacts, you probably won't want to map *every*
> annotation (or class, for that matter).
Of course, @Override, or even better @SuspessWarnings don't carries much
semantic weight in the scope of the model. But as you will need to apply
a profile to the model, to apply stereotypes, only annotations mapping
to stereotypes defined by the applied profiles could be processed.
So the deeps of the mapping is controlled by the applied profiles. This
looks like a clean solution.

greetings, urs.
Previous Topic:Primitive types and Java types in XMI
Next Topic:UML2 from eclipse and customer requirements
Goto Forum:
  


Current Time: Sat Aug 30 16:32:57 EDT 2014

Powered by FUDForum. Page generated in 0.02537 seconds