Selection Sequence - modelint/shlaer-mellor-metamodel GitHub Wiki

A selection sequence may be defined by specifying ascending or descending order for any Attributes of the Class characterizing with the Iteration Input. Any ordering Attribute must have a type that supports greater than/less than comparison operations.

We can order a set of Aircraft instances as follows:

<< Aircraft( +^Altitude, -^Airspeed ) >> {
    LOG.LogData( Item1: Altitude, Item2: Airspeed )
}

All instances of Aircraft in the Iteration Instance Input flow are ordered by ascending Altitude and descending Airspeed.

If two or more Aircraft share the same values for the ordering attributes, the order of iteration on those instances will be indeterminate.

In the example above, let's say that two of the Aircraft instances in the input are at Altitude:10000 and Airspeed:376. Those two instances may be processed in either order.

If strict ordering is essential, the modeler may want to instead define an Ordinal Relationship and Ordinal Sequence on the source Class.

Identifiers

  1. Iteration action + Activity + Domain

Attributes

No non-referential attributes