Documentation Archive Developer
Search
PATH  Documentation > WebObjects 4.5 > EOControl Reference

Table of Contents

EOSortOrderingComparison


(informal protocol)
Declared in:
EOControl/EOSortOrdering.h



Protocol Description


The EOSortOrderingComparison informal protocol defines methods for comparing values. These methods are used for sorting value objects.


Note: This interface doesn't exist in the Yellow Box package, com.apple.yellow.eocontrol

Though declared for NSObject, most of these methods work properly only with value classes: NSString, NSDate, NSNumber, NSDecimalNumber, and EONull.



Instance Methods



compareAscending

Returns NSOrderedAscending if anObject is naturally ordered after the receiver, NSOrderedDescending if it's naturally ordered before the receiver, and NSOrderedSame if they're equivalent for ordering purposes. NSObject's implementation of this method simply invokes compare:.

compareCaseInsensitiveAscending

Returns NSOrderedAscending if anObject is naturally ordered-ignoring case-after the receiver, NSOrderedDescending if it's naturally ordered before the receiver, and NSOrderedSame if they're equivalent for ordering purposes. NSObject's implementation of this method invokes compare:, while NSString's invokes caseInsensitiveCompare:.

compareCaseInsensitiveDescending

Returns NSOrderedAscending if anObject is naturally ordered-ignoring case-before the receiver, NSOrderedDescending if it's naturally ordered after the receiver, and NSOrderedSame if they're equivalent for ordering purposes. NSObject's implementation of this method invokes compare: and inverts the result, while NSString's invokes caseInsensitiveCompare: and inverts the result.

compareDescending

Returns NSOrderedAscending if anObject is naturally ordered before the receiver, NSOrderedDescending if it's naturally ordered after the receiver, and NSOrderedSame if they're equivalent for ordering purposes. NSObject's implementation of this method simply invokes compare: and inverts the result.


Table of Contents