NSCharacterSet(HTML) Category Reference
Declared in | NSCharacterSet+HTML.h |
Overview
Category on NSCharacterSet to create character sets frequently used and relevant to HTML and CSS string manipulations. Each character set is only initialized once.
Tasks
HTML Character Sets
-
+ tagNameCharacterSet
-
+ tagAttributeNameCharacterSet
-
+ ignorableWhitespaceCharacterSet
-
+ quoteCharacterSet
-
+ nonQuotedAttributeEndCharacterSet
CSS Character Sets
Class Methods
cssLengthUnitCharacterSet
Characterset of characters that make up units in CSS lengths
+ (NSCharacterSet *)cssLengthUnitCharacterSet
Return Value
An NSCharacterSet
Declared In
NSCharacterSet+HTML.h
cssLengthValueCharacterSet
Characterset of characters that make up units in CSS values
+ (NSCharacterSet *)cssLengthValueCharacterSet
Return Value
An NSCharacterSet
Declared In
NSCharacterSet+HTML.h
cssStyleAttributeNameCharacterSet
Creates an alpha-numeric character set just as tagNameCharacterSet does but also with the dash and underscore characters. Does not contain the colon character because it will mess up parsing of CSS style attributes. Useful for CSS attribute names.
+ (NSCharacterSet *)cssStyleAttributeNameCharacterSet
Return Value
An NSCharacterSet with alpha-numeric characters, dash, and underscore characters.
Declared In
NSCharacterSet+HTML.h
ignorableWhitespaceCharacterSet
Creates a characterset of all whitespace and newline characters that can be ignored between HTML tags
+ (NSCharacterSet *)ignorableWhitespaceCharacterSet
Return Value
An NSCharacterSet of ignorable characters
Declared In
NSCharacterSet+HTML.h
nonQuotedAttributeEndCharacterSet
Creates a character set with the characters forward slash / and closing angle bracket aka greater than sign >, then forms the union of this character set with the whitespace character set which includes space, tab, newline, and nextline characters. Useful to find the end of an attribute.
+ (NSCharacterSet *)nonQuotedAttributeEndCharacterSet
Return Value
An NSCharacterSet with the forward slash, closing angle bracket characters, tab, space, newline, and nextline characters.
Declared In
NSCharacterSet+HTML.h
quoteCharacterSet
Creates a character set with the apostrophe character ‘ (used as single quote agnostic of direction) and double quote character “ (agnostic of direction).
+ (NSCharacterSet *)quoteCharacterSet
Return Value
An NSCharacterSet with the single quote and double quote characters: ‘, “.
Declared In
NSCharacterSet+HTML.h
tagAttributeNameCharacterSet
Creates an alpha-numeric character set just as tagNameCharacterSet does but also with colon, dash, and underscore characters, appropriate for tag attribute names.
+ (NSCharacterSet *)tagAttributeNameCharacterSet
Return Value
An NSCharacterSet with alpha-numeric characters and colon :, dash -, and underscore _‘.
Declared In
NSCharacterSet+HTML.h