Samond Classes Library 1.2.1-RELEASE build 181
|
Indexed collections protocol. More...
#import <SCCollectionProtocols.h>
Querying a Collection | |
(id) | - firstObject |
(id) | - lastObject |
(id) | - objectAtIndex: |
Finding Objects in a Collection | |
(SCIndex) | - indexOfObject: |
(SCIndex) | - indexOfLastObject |
Indexed collections protocol.
Declares the mandatory methods for support indexed collections.
- (id) firstObject |
Returns the first object from the receiving collection.
- (SCIndex) indexOfLastObject |
Returns the index of the last object within the receiving collection.
Reimplemented in NSOrderedSet(SCOrderedSet), and NSArray(SCArray).
- (SCIndex) indexOfObject: | (id< SCCollectioning >) | object |
Returns the lowest index whose corresponding collection value is equal to a given object.
object | - desired object |
Reimplemented in SCArray, and SCOrderedSet.
- (id) lastObject |
Returns the last object from the receiving collection.
- (id) objectAtIndex: | (SCIndex) | index |
Returns the object located at the specified index.
index | - required object index |
SCCollectionException | - collection error detected |
Reimplemented in SCArray, and SCOrderedSet.