Hi All,
I am struggling with what seems like a simple problem.
I have defined two classes such that one class contains an array of the other:
dog <>-------leg
and the relationship is established by a "aggregation" (solid diamond).
In a separate diagram, I make instances Rex:dog, Shep:dog and RexLeg:leg. What is the EA mechanism to associate the instances according to the already-defined aggregation relationship? RexLeg is a part of Rex, but not a part of Shep. Right now my instance diagram shows Rex, Shep, RexLeg all unconnected.
I tried, in the instance diagram, to right-click on Rex:dog then Add | Related elements..., but that did not work. I tried drawing a new aggregation on the instance diagram, but that seemed to be a new relationship. I tried hunting in the project browser for the aggregation object so that I could drag it into the instance diagram, but aggregation relationships are not recorded in the project browser.
Another instance question, if I may. If the class has member int NumLegs, what is the proper way (in EA) to specify, for a specific class instance (such as Rex), that Rex.NumLegs = 4? One solution is to add a constraint to the instance "NumLegs == 4", but its unclear that EA is recognizing the use of the member names in the contraint dialog (it seems that I could write just about anything into a "constraint").
Thanks for any input on these issues.
Regards,
Owen