Ranges

These functions are used to create and manipulate NSRange structures.

NSEqualRanges

BOOL NSEqualRanges(NSRange range1, NSRange range2)

NSIntersectionRange

NSRange NSIntersectionRange(NSRange range1, NSRange range2)

NSLocationInRange

BOOL NSLocationInRange(unsigned int index, NSRange aRange)

NSMakeRange

NSRange NSMakeRange(unsigned int location, unsigned int length)

NSMaxRange

unsigned int NSMaxRange(NSRange range)

NSRangeFromString

NSRange NSRangeFromString(NSString *aString)

NSStringFromRange

NSString *NSStringFromRange(NSRange range)

NSUnionRange

NSRange NSUnionRange(NSRange range1, NSRange range2)

Get Cocoa in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.