UML 2.2 RTF Avatar
  1. OMG Issue

UML22 — Optional name attribute in NamedElement is misleading and insufficient

  • Key: UML22-184
  • Legacy Issue Number: 9256
  • Status: closed  
  • Source: Borland Software Corporation ( Stephen Palmer)
  • Summary:

    find it very unintuitive that the name attribute of a NamedElement is optional and If specified may be any valid string, including the empty string. A more accurate name for an element that has the capacity to have a name but does not necessarily have one would be, NameableElement instead of the misleading NamedElement.
    However, elements that do not have a name (or that have a name comprising solely of the empty string or white space characters) have no means through which a human can precisely reference them other than through their physical location on a diagram. This leaves open an opportunity for ambiguity in referencing elements and possible mis-communication. For this reason, the name attribute of NamedElement should be required, should not be allowed to contain just the empty string or just white space characters and should be unique within the element's package. In practise, even an artificially generated name for an element is preferable to no name at all.

    The question of whether the name of an element should be displayed on a particular diagram is a completely different subject and should, in general, be a decision made on a case-by-case basis by the modeller. However, even when the name is not displayed on a diagram, requiring elements to have a readable name provides tool-makers with opportunities to show the name of the element in tool tips, status bars, model navigation panes, etc so that the element can still be readily identified and precisely distinguished from others by human users of the model.

    It is very common in many organizations to have both a short name for an element and a longer more descriptive name for an element. For example, a use case may have the short name UC-OP0001 and a longer name 'Place Order'. The current NamedElement has no provision for such a scheme. In practise, it would be frequently very useful NamedElements had an optional longer name as well as a required short name attribute. Whether the short or long name (when provided) are used on a particular diagram or in any other context is again a matter for the modeller and tool-makers.

  • Reported: UML 2.0 — Fri, 20 Jan 2006 05:00 GMT
  • Disposition: Resolved — UML 2.2
  • Disposition Summary:

    Discussion
    The use of NamedElements with no names is well established in a number of cases in UML. Tools can provide all the
    advantages described by the issue author if the modeler gives a NamedElement a name, but it is more convenient to
    allow the modeler the choice of whether to do that.
    Disposition: Closed - No Change

  • Updated: Fri, 6 Mar 2015 20:58 GMT