Ordered Bag in UML

2019-08-05 09:42发布

问题:

When a UML Class diagram association takes <orderedSet> annotation, it seems it means there is an order (yet unknown) between the elements at the end of the association. For example:

A ---> <orderedSet> B

means that for each a:A, its associated set of elements from B are ordered (e.g., a --> <b1,b2,b5>)

My Question: How is it possible to define the end of an association to be ordered Bag (multi-Set) in UML? ( in above example context, I am looking for the possibility of a --> <b1,b2,b1,b5>).

Thanks

回答1:

See also:

  • uml-diagrams.org: Multiplicity Element
  • Chapter 7.5.3 "Common Structure → Types and Multiplicity → Semantics → Multiplicities" in www.omg.org/spec/UML/2.5/Beta2