@Immutable public class XmlNameEncoder extends Object implements TextDecoder, TextEncoder
decoderfor XML element and attribute names.
Any UTF-16 unicode character that is not a valid XML name character according to the World Wide Web Consortium (W3C) Extensible Markup Language (XML) 1.0
(Fourth Edition) Recommendation is escaped as
HHHH stands for the four-digit
hexadecimal UTF-16 unicode value for the character in the most significant bit first order. For example, the name "Customer_ID"
is encoded as "Customer_x0020_ID".
Decoding transforms every
_xHHHH_ encoding sequences back into the UTF-16 character. Note that
decoding can be safely done on any XML name, even if the name does not contain any encoded sequences.
|Constructor and Description|
|Modifier and Type||Method and Description|
Return the decoded version of an encoded string
Returns the encoded version of a string.
Copyright © 2008–2016 JBoss, a division of Red Hat. All rights reserved.