OCLOperators orderGeneric
Created by Alexandra on 2017-08-13 · Last edited by Peter.byaruhanga on 2026-01-24.
Sorts the list of properties with interchangeable sort order: (expr1, OclSortDirection::ascending, expr2, OclSortDirection::descending...)
Example
If We have a class Car with attributes Name and Country.
We can use orderGeneric like this.
Car.allInstances->orderGeneric(Name, OclSortDirection::ascending)