public interface XmlNameProcessor extends Serializable
Processors should be set in the XmlMapper.setXmlNameProcessor(com.fasterxml.jackson.dataformat.xml.XmlNameProcessor)
and/or the XmlMapper.Builder.xmlNameProcessor(com.fasterxml.jackson.dataformat.xml.XmlNameProcessor)
methods.
See XmlNameProcessors
for default processors.
Modifier and Type | Interface and Description |
---|---|
static class |
XmlNameProcessor.XmlName
Representation of an XML element or attribute name
|
Modifier and Type | Method and Description |
---|---|
void |
decodeName(XmlNameProcessor.XmlName name)
Used during XML deserialization.
|
void |
encodeName(XmlNameProcessor.XmlName name)
Used during XML serialization.
|
void encodeName(XmlNameProcessor.XmlName name)
This method should process the provided XmlNameProcessor.XmlName
and
escape / encode invalid XML characters.
name
- The name to encodevoid decodeName(XmlNameProcessor.XmlName name)
This method should process the provided XmlNameProcessor.XmlName
and
revert the encoding done in the encodeName(XmlName)
method.
Note: Depending on the use case, it is not always required (or even possible) to reverse an encoding with 100% accuracy.
name
- The name to encodeCopyright © 2022 FasterXML. All rights reserved.