While any list can be ordered by using a property of the objects it contains, it is sometimes necessary to specify an order. Ordered lists are composed of the following elements:
To begin, an Ordered Property List Type is created within the schema. It contains an additional property used to indicate what type of Ordering Property Collection Type the list should contain.
This extra property will allow applications to dynamically analyze the list and know what type of objects should be created to store the ordering information.
This type should have no property instance and no deduction rules defined.
The Ordering Property Collection Type acts as an intermediary between the list and it's ordered content. It behaves as a standard property collection, but it contains two additional properties in it's type defintion :
The value instance can be of any property collection type.
The ordering must be of a type that can be compared. Therefore, basic types such as Strings, Integers and Calendars are normally used.
While the Ordering Property Collection Type can contain more than those two instances, it is not recommended to do so as most user interface implementation will hide the Ordering Property Collection Type from the view when browsing a list, making those extra properties hidden from the end user.
Deduction rules can be used to automatically set the ordering instance based on a property held within the value instance. This can be used to order a list of collections by name for instance.
Here is a sample guide to create an ordered list. In this example, we will assume we have an type named "shelf" and a type named "book". We want to add an ordered list of "book" to the "shelf".