Community
Participate
Working Groups
It would be mighty nice to have the ability to specify the order of ordered association and to have this shown on instance diagram. This request can be extended to all ordered items in a model (but the above is really missing) Thanx! *Yoram
This request has now become quite important. In order to document certain use cases it is essential that ordered associations and association class can be displayed on the diagram *with the order* shown. Some of my diagrams are meaningless without the order (I decorate with tex now but this is really lame). Is there a plan to address this request at some near future date? === I can suggest that for flat associations, the order would show up as an enumerator next to the label of the ordered end. Note that if the latter, I should be able to delete the label of the end name but leave the enumerator on the diagram To be consistent I propose that the same behavior (association end label enumerator) would be manifested for association classes (no additional attribute!) It is highly desired to be able to edit the enumerator and assign an arbitrary value to it. === Thanx! *Yoram
(In reply to comment #1) > This request has now become quite important. In order to document certain use > cases it is essential that ordered associations and association class can be > displayed on the diagram *with the order* shown. Some of my diagrams are > meaningless without the order (I decorate with tex now but this is really > lame). > > Is there a plan to address this request at some near future date? > > === > I can suggest that for flat associations, the order would show up as an > enumerator next to the label of the ordered end. Note that if the latter, I > should be able to delete the label of the end name but leave the enumerator on > the diagram > > To be consistent I propose that the same behavior (association end label > enumerator) would be manifested for association classes (no additional > attribute!) > > It is highly desired to be able to edit the enumerator and assign an arbitrary > value to it. > === > > Thanx! > *Yoram Navid? Could you work with Yoram to gather all the details needed and bump this up in our priority list? Thanks, Eric
Created attachment 184313 [details] Ordered associations I've clarified this with Yoram after a few E-mail exchanges a couple of weeks ago. Here's the final requirements that we concluded on: - When an association end is ordered, we indicate this via a label in class diagram (e.g. {ordered}) User will be able to hide/show this label in diagram - If an instance of an association or association class is created in an instance diagram that has an ordered association end, user will be able to right click on association > select 'Set Order' > aEnd or zEnd (disable where appropriate) > and set an arbitrary order on the corresponding association end. This label can be hidden/shown similar to other association labels.
Yoram, I'm prioritizing the list of defect/enhancements for I27. How important is this enhancement to your work? Should I schedule it in I27?
(In reply to comment #4) > Yoram, I'm prioritizing the list of defect/enhancements for I27. How important > is this enhancement to your work? Should I schedule it in I27? Navid, if you're asking me to prioritize it I need to know what to prioritize it against. It would be nice to have (and would make some of my diagrams much better looking but if there are other features in the candidate list then I may prefer something else. If this is the ONLY feature on the list then its priority is the highest and lowest at the same time... *Yoram
Fair enough. I don't think I'll schedule this enhancement just yet. Hopefully we'll get to it in the next couple of iterations.
Created attachment 185909 [details] 230101 class diagram Patch for ordered associations on class diagrams.
Created attachment 187167 [details] 230101 patch
"230101 patch" applied.
I see multiple issues with this feature. Here's what I did: - Create a Model project called p1 - Create two entities A and B - Created an association between A and B and modified the aEnd to specify a multiplicity of 0..* and set 'isOrdered' to true. When all artifacts are added to class diagram, the aEnd doesn't get decorated with '{ordered}' label as requested by this enhancement. Note that user should have the ability to filter this label via 'Hide/Show Details' context menu option. I then create an instance diagram > Add entity A to diagram > Right click on Entity > 'Add Related Instances...' > Select B > OK. Right click on association > Set Order > aEnd > The 'Set Order' dialog displayed is not in the expected format. There should just be a label called 'Order Type' with a text box that accepts an arbitrary value. When user enters the value, it should appear as a label on corresponding aEnd/zEnd of association. User should have the ability to hide/show this label via 'Hide/Show Details' context menu option similar to class diagrams. This enhancement can be moved to I30 if there aren't enough cycles to complete it in I29.
Sorry, I didn't leave any comments about implementation details. Order qualifiers could be enabled/disabled from "Hide/Show -> Hide Order Qualifiers" diagram context menu (similar to Stereotypes). By default the order qualifiers are hidden. Instance diagram has the same menu. I assumed that order can be specified by an integer value only. So in "Set Order" dialog you could specify a custom order number or if you have n associations you can sort them, in this case assigned order values will be from 1 to n. If order number isn't specified then displayed value is "unknown".
Anton, the Set Order dialog should have a free form text field where the user can enter any order they wish (text or integer). Whatever that's entered should be displayed as a label in the instance diagram. Yoram, if you like to propose a different solution, please comment.
Created attachment 187831 [details] 230101_c12 patch Set Order dialog updated, now it contains only free form text field.
Applied 230101_c12 patch.
Hey Anton, just tried this out. I don't see a label in the class diagram when 'isOrdered' bit is set. In an instance diagram, I don't see the order value that's set via Set Order dialog. Let's discuss on Monday.
Created attachment 188038 [details] 230101_c15 Order qualifiers are enabled by default. Menus for enabling/disabling order qualifiers are moved from diagram menu to association context menu.
Applied 230101_c15 patch.
Excellent Anton! It now works as expected. Yoram, you may also want to try out this feature once the push is completed tomorrow.