Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Character Range

A character range R identifies a set of characters C(R) containing all XML characters with Universal Character Set (UCS) code points in a specified range.

charRange ::= seRange | XmlCharRef | XmlCharIncDash
seRange ::= charOrEsc '-' charOrEsc
XmlCharRef ::= ( '&#' [0-9]+ ';' ) | ('&#x' [0-9a-fA-F]+ ';' )
charOrEsc ::= XmlChar | SingleCharEsc
XmlChar ::= [^\#x2D#x5B#x5D]
XmlCharIncDash ::= [^\#x5B#x5D]

A single XML character is a character range that identifies the set of characters containing only itself. All XML characters are valid character ranges expect as follows:

  • The left bracket ([), right bracket (]), and backslash (\) character range are not valid character ranges.

  • The caret (^) character is a valid character range at the beginning of a positive character group only if it is part of a negative character group.

  • The subtraction (–) character is a valid character range only at the beginning or end of a positive character group.

A character range may also be written in the form s-e, identifying the set that contains all XML characters with UCS code points that are greater than or equal to the code point of s, but not greater than the code point of e.

The form s-e is a valid character range if:

  • s is a single character escape, or an XML character.

  • s is not "\".

  • s is the first character in a character class expression, then s is not "^".

  • e is a single character escape, or an XML character.

  • e is not "\" or "[;".

  • the code point of e is greater than or equal to the code point of s.

    noteNote:
    The code point of a single character escape is the code point of the single character in the set of characters that it identifies.




Build Date:

2012-08-02
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.