DLRFoundation可以通过CocoaPods获得。要安装它,只需将以下行添加到Podfile中:
pod "DLRFoundation"
Nathan Walczak,[email protected]
DLRFoundation可在MIT许可证下使用。更多信息请参阅LICENSE文件。
/** Returns a filter array with only objects of a specific kind of class.
An empty array is returned if none found. */
- (NSArray *)dlr_filteredArrayWithKindOfClass:(Class)aClass;
/** Returns the object located after specificed object.
If last object, returns first object. */
- (id)dlr_objectAfterObject:(id)object;
/** Returns the object located before specificed object.
If first object, returns last object. */
- (id)dlr_objectBeforeObject:(id)object;
/** Returns true if the array contains an instance of the specified class or its
subclasses. */
- (BOOL)dlr_containsKindOfClass:(Class)aClass;
/** Returns true if the array contains a member of the specified class. */
- (BOOL)dlr_containsMemberOfClass:(Class)aClass;
/** Returns a string by trimming all of the leading and trailing whitespace characters.
If the receiver is composed entirely of whitespace characters, an empty string is returned. */
- (NSString *)dlr_stringByTrimmingWhitespaceCharacters;
/** If the receiver has a lenght of zero, nil is returned. Otherwise the receiver is returned. */
- (NSString *)dlr_nilIfEmpty;