NSString 0.1 28 February, 2000 NSString Foundation/NSString.h NSCoding

NSString objects represent an immutable string of characters. NSString itself is an abstract class which provides factory methods to generate objects of unspecified subclasses.

A constant NSString can be created using the following syntax: @"...", where the contents of the quotes are the string, using only ASCII characters.

availableStringEncodings

Returns an array of all available string encodings, terminated by a null value.

defaultCStringEncoding

Returns the encoding used for any method accepting a C string.

localizedNameOfStringEncoding: encoding

Returns the localized name of the encoding specified by encoding.

localizedStringWithFormat: format, pathWithComponents: components string stringWithCharacters: chars length: length stringWithContentsOfFile: path stringWithCString: cString stringWithCString: cString stringWithFormat: format, stringWithString: aString canBeConvertedToEncoding: encoding capitalizedString caseInsensitiveCompare: aString characterAtIndex: index commonPrefixWithString: aString compare: aString compare: aString compare: aString options: mask range: aRange completePathIntoString: outputName caseSensitive: flag matchesIntoArray: outputArray componentsSeparatedByString: separator cString cStringLength dataUsingEncoding: encoding dataUsingEncoding: encoding allowLossyConversion: flag description doubleValue fastestEncoding fileSystemRepresentation floatValue getCharacters: buffer getCharacters: buffer getCString: buffer getCString: buffer maxLength: maxLength getCString: buffer maxLength: maxLength range: aRange remainingRange: leftoverRange getFileSystemRepresentation: buffer maxLength: maxLength getLineStart: startIndex end: lineEndIndex contentsEnd: contentsEndIndex hash hasPrefix: aString hasSuffix: aString init initWithCharacters: characters initWithCharactersNoCopy: characters length: length freeWhenDone: flag initWithContentsOfFile: path initWithCString: cString initWithCString: cString initWithCStringNoCopy: cString length: length freeWhenDone: flag initWithData: data encoding: encoding initWithFormat: format, initWithFormat: format arguments: argList initWithFormat: format initWithFormat: format locale: dictionary arguments: argList initWithString: aString intValue isAbsolutePath isEqualToString: aString lastPathComponent length lineRangeForRange: aRange lossyCString lowercaseString pathComponents pathExtension propertyList propertyListFromStringsFileFormat rangeOfCharacterFromSet: aSet rangeOfCharacterFromSet: aSet options: mask rangeOfCharacterFromSet: aSet options: mask range: aRange rangeOfComposedCharacterSequenceAtIndex: anIndex rangeOfString: aString Invokes rangeOfString:options: with the options mask set to zero. rangeOfString: aString options: mask Invokes rangeOfString:options:range with the range set set to the range of the whole of the reciever. rangeOfString: subString options: mask range: aRange Returns the range giving the location and length of the first occurrence of subString within aRange.
If subString does not exist in the receiver (an empty string is never considered to exist in the receiver), the length of the returned range is zero.
If substring is nil, an exception is raised.
If any part of aRange lies outside the range of the receiver, an exception is raised.
The optionsm mask may contain the following options - NSCaseInsensitiveSearch NSLiteralSearch NSBackwardsSearch NSAnchoredSearch
smallestEncoding stringByAbbreviatingWithTildeInPath stringByAppendingFormat: format, stringByAppendingPathComponent: aString stringByAppendingPathExtension: string stringByAppendingString: aString stringByDeletingLastPathComponent stringByDeletingPathExtension stringByExpandingTildeInPath stringByReplacingString: aString withString: replacement Returns a string in which any (and all) occurrances of aString in the receiver have been replaced by replacement. Returns the receiver if aString does not occur within the receiver. NB. an empty string is not considered to exist within the receiver. stringsByAppendingPaths: paths substringFromIndex: anIndex substringToIndex: anIndex substringWithRange: aRange uppercaseString writeToFile: path atomically: flag