- Declared In:
- NSSet+Extensions.h
Adding objectsMapping the set
- - setByAddingObjectsFromSet:
- - setByAddingObjectsFromArray:
- - setByMappingWithDictionary:
- - setByMappingWithSelector:
- - setByMappingWithSelector:withObject:
- (NSSet *)setByAddingObjectsFromArray:(NSArray *)anArray
Adds all objects from anArray to the receiver.
- (NSSet *)setByAddingObjectsFromSet:(NSSet *)otherSet
Adds all objects from otherSet to the receiver.
- (NSSet *)setByMappingWithDictionary:(NSDictionary *)mapping
Uses each object in the receiver as a key and looks up the corresponding value in mapping. All these values are added to the set returned. Note that this method raises an exception if any of the objects in the receiver is not found as a key in mapping. Note also, that the returned set can be smaller than the receiver.
- (NSSet *)setByMappingWithSelector:(SEL)selector
Invokes the method described by selector in each object in the receiver. All returned values are added to the set returned. Note that the returned set can be smaller than the receiver.
- (NSSet *)setByMappingWithSelector:(SEL)selector withObject:(id)object
Invokes the method described by selector in each object in the receiver passing object as an argument. All returned values are added to the set returned. Note that the returned set can be smaller than the receiver.