Re: UML-ish question
- From: Alec Ross <alec@xxxxxxxxxxxxxxxxxxx>
- Date: Sat, 25 Mar 2006 19:37:49 +0000
In message <1143042024.687189.59020@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>, "jhinchey@xxxxxxxxxx" <jhinchey@xxxxxxxxxx> writes
I came across something on a UML class diagram today that I have neverYes.
seen before and I'm wondering about the validity of it. The diagram
has a class which has an association with itself (a line coming out of
the class, making 2 90 degree turns and going back into itself).
Is that legal UML?
If so, what does it mean?It denotes that in general, one instance of the class can have a link to another instance of that class. But for a Singleton object, it would be a link with itself.
The exact meaning will depend on the meaning of the association. E.g. for a Component class, it could be that a component object could contain other components, or, for say an electrical component, the association could model electrical connection between one component and other(s).
I think they are tryingYou could have objects on a "class diagram", but usually it's just classes. And a line between objects represents a link, of course. A line drawn between two classes represents an association - which models, basically, the potential for links between objects of the classes involved. And for there to be a reflexive association is certainly legal.
to show an association between two instances of the class, which I
don't think belongs on the class diagram.
--
Alec Ross
.
- References:
- UML-ish question
- From: jhinchey@xxxxxxxxxx
- UML-ish question
- Prev by Date: Re: multimethod + multiple inheritance
- Next by Date: Tools for drawing simple object/pattern diagrams?
- Previous by thread: Re: UML-ish question
- Next by thread: Re: PAC (presentation-abstraction-control) question
- Index(es):