Trying to define attribute in class in diagram of type "Set<ComponentType>" [message #501797] |
Thu, 03 December 2009 15:03  |
Eclipse User |
|
|
|
I have a simple class diagram, with classes "Catalog" and "Category". I'll be adding many more classes, but these are the first two. There is a property of "Catalog" called "rootCategories", which should be a "Set<Category>". It's easy enough to define an association from Catalog to Category and label it on the source end with "rootCategories", but I'd like to define a "rootCategories" attribute of "Catalog" of type "Set<Category>".
I've created the two class icons, along with the association, but I don't understand the steps required to get that attribute created with that type.
|
|
|
|
Re: Trying to define attribute in class in diagram of type "Set<ComponentType>" [message #501931 is a reply to message #501797] |
Fri, 04 December 2009 09:02   |
Eclipse User |
|
|
|
David,
Your question appears to be about Java generics but that isn't directly
supported by UML itself. I suppose something equivalent is a
multi-valued property that's unordered and unique, but even this, if
mapped to Ecore and then to Java will result in EList<Category> not
Set<Category>...
David M. Karr wrote:
> I have a simple class diagram, with classes "Catalog" and "Category".
> I'll be adding many more classes, but these are the first two. There
> is a property of "Catalog" called "rootCategories", which should be a
> "Set<Category>". It's easy enough to define an association from
> Catalog to Category and label it on the source end with
> "rootCategories", but I'd like to define a "rootCategories" attribute
> of "Catalog" of type "Set<Category>".
>
> I've created the two class icons, along with the association, but I
> don't understand the steps required to get that attribute created with
> that type.
|
|
|
|
|
|
Re: Trying to define attribute in class in diagram of type "Set<ComponentType>" [message #502021 is a reply to message #502018] |
Fri, 04 December 2009 14:32  |
Eclipse User |
|
|
|
Vlad,
I make no claims to be a credible UML expert let alone an expert in the
tools. I simply help as best I can when no one else steps in to do better.
Of course you copied my previous reply. It's a bit juvenile, but that
seems to keep you entertained.
Vlad Varnica wrote:
> Ed answer below:
>
> Quote:
>> Unfortunately I know nothing about how to use the UML graphical
>> editor to achieve your, so I'm not sure what steps you need to take.
>> Maybe someone else will help with the specifics of your question.
>
>
> Do we really need such an answer ? you undermine any shred of
> credibility you might still have left on UML modeling.
>
> PS: Please don't say I copied your previous reply, I know and this
> intentional :)
>
>
|
|
|
|
Re: Trying to define attribute in class in diagram of type "Set<ComponentType>" [message #625328 is a reply to message #625327] |
Fri, 04 December 2009 10:45  |
Eclipse User |
|
|
|
David,
I believe in UML terminology it's just a many-valued (unbounded
multiplicity) property and that the fact it's a set, collection, or list
is implicit in things like the property being unordered and unique.
Unfortunately I know nothing about how to use the UML graphical editor
to achieve your, so I'm not sure what steps you need to take. Maybe
someone else will help with the specifics of your question.
David M. Karr wrote:
> Just show me the best reasonable compromise, in order to show in the
> UML diagram that it represents a Set of a particular component type.
> If you can't show the component type, I can live with that. If you
> can't use the word "Set", I can live with that. What's the best I can
> get, and how do I do it? There are some steps in defining UML in this
> plugin that are not obvious.
|
|
|
Re: Trying to define attribute in class in diagram of type "Set<ComponentType>" [message #625380 is a reply to message #501968] |
Fri, 04 December 2009 14:25  |
Eclipse User |
|
|
|
Ed answer below:
Quote:
> Unfortunately I know nothing about how to use the UML graphical editor to achieve your, so I'm not sure what steps you need to take. Maybe someone else will help with the specifics of your question.
Do we really need such an answer ? you undermine any shred of credibility you might still have left on UML modeling.
PS: Please don't say I copied your previous reply, I know and this intentional :)
|
|
|
Re: Trying to define attribute in class in diagram of type "Set<ComponentType>" [message #625381 is a reply to message #625380] |
Fri, 04 December 2009 14:32  |
Eclipse User |
|
|
|
Vlad,
I make no claims to be a credible UML expert let alone an expert in the
tools. I simply help as best I can when no one else steps in to do better.
Of course you copied my previous reply. It's a bit juvenile, but that
seems to keep you entertained.
Vlad Varnica wrote:
> Ed answer below:
>
> Quote:
>> Unfortunately I know nothing about how to use the UML graphical
>> editor to achieve your, so I'm not sure what steps you need to take.
>> Maybe someone else will help with the specifics of your question.
>
>
> Do we really need such an answer ? you undermine any shred of
> credibility you might still have left on UML modeling.
>
> PS: Please don't say I copied your previous reply, I know and this
> intentional :)
>
>
|
|
|
Powered by
FUDForum. Page generated in 1.27906 seconds