SUBSYSTEM OVERVIEW

Object List Manager (OLM) Subsystem

The OLM subsystem is used to maintain lists of objects. The objects may be a single data type or a structure of many data types. The objects will be stored by a specified position in the list. The list will not be sorted, use the object tree manager for this.

USAGE

To use the object list manager you must first create a list by executing olm_CreateList. After a list has been created, objects may be added to the list with olm_AddObject. The position in the list of where to add the object must be specified and may be either a numeric value or OLM_FIRST, OLM_LAST, or OLM_CURRENT. Arrays of objects may be added using the olm_AddArray function. Objects may be removed from a list with olm_RemoveObject or all objects may be removed with olm_RemoveAll. Objects may be retrieved with either olm_GetObject to get a single object pointer, or olm_GetArray to get an array of objects. The list may be cycled using olm_CycleList to get the object pointers one at a time. The mpm_LastError function should be used after cycling, since an error and the end of a list both return a NULL pointer. A new list may be created with either olm_CopyList or olm_MergeList. The olm_CopyList function makes a duplicate copy of the specified list and all its objects. The olm_MergeList function will combine two lists into one using either the OLM_UNION, OLM_DIFFERENCE, or OLM_INTERSECTION operator. When finished with the list, olm_DeleteList should be called to free all memory associated with the list.