Naming conventions

Here are some naming conventions for xUML model element and variable names.

Symbol names

Symbols include variable, attribute, class, parameter, event, method and operation names.

Internal spaces allowed

Symbol names follow the usual alphanumeric conventions with the exception that the space character may be used as a delimiter. So the name incoming aircraft, for example, is a legal name.

System symbol names

Values and functions provided by the model execution platform are preceded by an underscore. For example, _now is a globally readable model execution variable with a few read accessor operations defined such as HMS.

current time = _now.HMS  // Get current hours, minutes and seconds

Naming conventions

For ease of reading, a number of model naming conventions are recommended, but not enforced.

Variable names – Lower case: my aircraft .= /R1/Aircraft
Class names – All initial caps: Air Traffic Controller
External entity names – All caps: UI, ALARMS
Attribute names – First initial cap: Maximum altitude
Parameter names – All lower case: (landing runway, radio freq)
Constrained (user) data types – All initial caps: Compass Direction
Unconstrained (system) types – Lower case: integer, boolean
Relationship phrase names – Lower case: /R3/is taking off from
Event, operation and method names – First initial cap:

  • Event: Land planes -> Air Traffic Controller
  • Operation: UI.Send warning( Message )
  • Method: Off Duty Controller.Check break duration() Transitory states – First initial cap: Checking temperature
    Wait states – All Caps: RAISING LANDING GEAR

(Note that state names are never referenced in Scrall, but it is helpful to see all of model naming conventions in one place).

Case insensitive names

To avoid confusion and bad naming practices, symbol names are case insensitive.