11.3.15 Sort

bool Sort(const OEBinaryPredicate<T,T>&)

The OEIter<T>::Sort method sorts contents of the iterator and resets the iterator to its first item. The re-ordering is local to the given instance of the iterator (i.e., the container holding the items the iterator traverses is unchanged). Once this function is called the iterator is never delete safe, even if it normally would be.

The OEBinaryPredicate<T,T> passed to this function is used as the less comparison in the sort. It should return true if the first argument is less than the second argument and false otherwise. An item that is less than another item will appear first after sorting.