Re: Coding style question from ObjC newbie
Re: Coding style question from ObjC newbie
- Subject: Re: Coding style question from ObjC newbie
- From: email@hidden
- Date: Thu, 31 Oct 2002 21:37:52 -0600
- (unsigned int)replaceOccurrencesOfString:(NSString *)target
withString:(NSString *)replacement options:(unsigned)opts
range:(NSRange)searchRange
This method replaces all occurrences of target with replacement, in the
specified searchRange of the receiver, returning the number of
replacements. Raises an NSInvalidArgumentException if any of the
arguments are nil. Raises an NSRangeException if any part of
searchRange lies beyond the end of the receiver. If opts is
NSBackwardsSearch, the search is done from the end of the range. If
opts is NSAnchoredSearch, only anchored (but potentially multiple)
instances are replaced. NSLiteralSearch and NSCaseInsensitiveSearch
also apply. Specify searchRange as NSMakeRange(0, [receiver length]) to
process the entire string.
On Thursday, October 31, 2002, at 03:31 PM, Nicholas Riley wrote:
>
@implementation NSString (Blah)
>
>
- (NSString *)stringByReplacingAllOccurrencesOfString:(NSString
>
*)findString withString:(NSString *)replacementString;
>
>
@end
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.