ftp.nice.ch/peanuts/GeneralData/Documents/openstep/OpenStepSpec_rtf.tar.gz#/OpenStepSpec_rtf/FoundationKit/Classes/NSCharacterSet.rtf

This is NSCharacterSet.rtf in view mode; [Download] [Up]

paperh18648 margl-907 margr0 margt0 margb0 fi0 ri0 ql sb0 f1 fs24 Copyright f3 'e3f1 1994 by NeXT Computer, Inc.  All Rights Reserved.

s4 li100 fi0 ri1007 ql f0 b fs36 fs100 
fs36 NSCharacterSet 
pard s11 li2872 fi-2771 ri1007 ql tx2872 f1 b0 fs28 fs48 
fs28 f0 b fs24 Inherits From:tab b0 fs28 f1 NSObject
fs20 
fs28 s6 f0 b fs24 Conforms To:tab b0 fs28 f1 NSCoding, NSCopying, NSMutableCopying
fi0 NSObject (NSObject)
fs20 
fs28 s7 fi-2771 f0 b fs24 Declared In:tab b0 fs28 f1 Foundation/NSCharacterSet.h 
fs20 
fs28 pard s16 li100 fi0 ri1007 ql f0 b fs28 fs20 
fs28 Class Description
fs14 
fs28 pard s1 li477 fi0 ri1007 ql tx2494 tx2872 tx3250 f1 b0 fs2 
fs28 The NSCharacterSet class declares the programmatic interface to objects that construct immutable i descriptionsi0  of character sets in the Unicode character encoding. Using NSCharacterSet objects, you can determine if a given Unicode character belongs to a specified set. See NSMutableCharacterSet for a class that constructs descriptions of character sets that can be modified dynamically. NSCharacterSet'27s primitive methods are b characterIsMember:b0  and b bitmapRepresentationb0 . Subclasses of NSCharacterSet must implement these two methods.
fs16 
fs28 NSCharacterSet objects can be thought of as loosely analogous to the b is'bcb0  macros (such as b isupper()b0 )available in the b ctypeb0  collection of most standard C libraries. NSCharacterSet objects, however, offer much greater flexibility in that you can dynamically construct your own custom character sets against which you can test characters.
fs16 
fs28 The term 'aabitmap'ba in the descriptions below does not refer to 'aabitmap characters'ba in the sense of screen fonts for display. The 'aabitmaps'ba referred to here are compact ordered i bit seti0  representations of Unicode character positions or ranges of Unicode characters.
fs16 
fs28 You create 'aastandard'ba character sets'd0such as a set of alphanumerics, or a set of decimal digits'd0by invoking the NSCharacterSet class object with one of the methods described in 'aaCreating a Standard Character Set'ba. These methods provide convenient means to create a standard set without needing to specify the character positons explicitly.
fs16 
fs28 You can also create your own 'aacustom'ba character sets by using one of the methods described under 'aaCreating a Custom Character Set'ba. To create a character set with multiple disjoint ranges, see the b addb0 'bc methods described in NSMutableCharacterSet.
fs16 
fs28 pard s16 li100 fi0 ri1007 ql f0 b fs24 
fs28 Creating a Standard Character Set 
fs14 
fs28 pard s8 li7029 fi-6552 ri1007 ql tx6652 tx7030 f1 b0 fs2 
fs28 fi-6552 + (NSCharacterSet *)b alphanumericCharacterSetb0 tab Returns a character set containing the uppercase and lowercase alphabetic characters (a{f3 -}z, A{f3 -}Z, other alphabetic characters such as 'dd, '89, 'db, '87, and so on) and the decimal digit characters (0{f3 -}9).
fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b controlCharacterSetb0 tab Returns a character set containing the control characters (characters with decimal Unicode values 0 to 31 and 127 to 159)fs28 .
fi-6552 fs28 fs16 
fs28 fi-6552 + (NSCharacterSet *)b decimalDigitCharacterSetb0 tab Returns a character set containing only decimal digit characters (0{f3 -}9).
fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b decomposableCharacterSetb0 tab Returns a character set containing all individual Unicode characters that can also be represented as composed character sequences.
fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b illegalCharacterSetb0 tab Returns a character set containing the illegal Unicode values.
fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b letterCharacterSetb0 tab Returns a character set containing the uppercase and lowercase alphabetic characters (a{f3 -}z, A{f3 -}Z, other alphabetic characters such as 'dd, '89, 'db, '87, and so on).
fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b lowercaseLetterCharacterSet
s9 li7030 fi-6553 fi-5796 b0 tab Returns a character set containing only lowercase alphabetic characters (a{f3 -}z, other alphabetic characters such as 'dd, 'db, and so on).
s8 li7029 fi-5794 fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b nonBaseCharacterSetb0 tab Returns a set containing all characters which are not defined to be base characters for purposes of dynamic character composition.
fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b uppercaseLetterCharacterSet
s9 li7030 fi-6553 fi-5796 b0 tab Returns a character set containing only uppercase alphabetic characters (A{f3 -}Z, other alphabetic characters such as '89, '87, and so on).
s8 li7029 fi-5794 fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b whitespaceAndNewlineCharacterSet
s9 li7030 fi-6553 fi-5796 b0 tab Returns a character set containing only whitespace characters (space and tab) and the newline character.
s8 li7029 fi-5794 fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b whitespaceCharacterSetb0 tab Returns a character set containing only in-line whitespace characters (space and tab). This set doesn'27t contain the newline or carriage return characters.
pard s16 li100 fi0 ri1007 ql f0 b fs48 
fs28 Creating a Custom Character Set 
fs14 
fs28 pard s8 li7029 fi-6552 ri1007 ql tx6652 tx7030 f1 b0 fs2 
fs28 fi-6552 + (NSCharacterSet *)b characterSetWithBitmapRepresentation:b0 (NSData *)i datai0 tab 
s9 li7030 fi-6553 fi-5796 tab Returns a character set containing characters determined by the bitmap representation i datai0 .
s8 li7029 fi-5794 fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b characterSetWithCharactersInString:b0 (NSString *)i aString
s9 li7030 fi-6553 fi-5796 i0 tab Returns a character set containing the characters in i aStringi0 . If i aStringi0  is empty, an empty character set is returned. i aStringi0  must not be b nilb0 .
s8 li7029 fi-5794 fi-6552 fs16 
fs28 fi-6552 + (NSCharacterSet *)b characterSetWithRange:b0 (NSRange)i aRange
s9 li7030 fi-6553 fi-5796 i0 tab Returns a character set containing characters whose Unicode values are given by i aRangei0 .
pard s16 li100 fi0 ri1007 ql f0 b fs48 
fs28 Getting a Binary Representation 
fs14 
fs28 pard s8 li7029 fi-6552 ri1007 ql tx6652 tx7030 f1 b0 fs2 
fs28 fi-6552 {f3 -} (NSData *)b bitmapRepresentationb0 tab Returns an NSData object encoding the receiving character set in binary format. This format is suitable for saving to a file or otherwise transmitting or archiving.
pard s16 li100 fi0 ri1007 ql f0 b fs48 
fs28 Testing Set Membership 
fs14 
fs28 pard s8 li7029 fi-6552 ri1007 ql tx6652 tx7030 f1 b0 fs2 
fs28 fi-6552 {f3 -} (BOOL)b characterIsMember:b0 (unichar)i aCharacteri0 tab Returns YES if i aCharacteri0  is in the receiving character set, NO if it isn'27t.
pard s16 li100 fi0 ri1007 ql f0 b fs48 
fs28 Inverting a Character Set 
fs14 
fs28 pard s8 li7029 fi-6552 ri1007 ql tx6652 tx7030 f1 b0 fs2 
fs28 fi-6552 {f3 -} (NSCharacterSet *)b invertedSetb0 tab Returns a character set containing only characters that i don'27ti0  exist in the receiver.
}

These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.