public class DomLexicalProcessor extends Object implements LexicalProcessor<String>
Constructor and Description |
---|
DomLexicalProcessor(SchemaRegistry schemaRegistry) |
Modifier and Type | Method and Description |
---|---|
boolean |
canRead(File file)
Checks if the processor can read from a given file.
|
boolean |
canRead(String dataString)
Checks if the processor can read from a given string.
|
MapXNode |
parseElementAsMap(Element element)
Parses the element in a single-entry MapXNode.
|
RootXNode |
parseElementAsRoot(Element element)
Parses the element into a RootXNode.
|
XNode |
parseElementContent(Element element)
Parses the content of the element (the name of the provided element is ignored, only the content is parsed).
|
RootXNode |
read(Document document) |
RootXNode |
read(Element rootElement) |
XNode |
read(File file,
ParsingContext parsingContext)
Deprecated.
|
RootXNode |
read(ParserSource source,
ParsingContext parsingContext) |
List<RootXNode> |
readObjects(ParserSource source,
ParsingContext parsingContext) |
Element |
serializeSingleElementMapToElement(MapXNode xmap) |
Element |
serializeUnderElement(XNode xnode,
QName rootElementName,
Element parentElement) |
Element |
serializeXMapToElement(MapXNode xmap,
QName elementName) |
String |
write(RootXNode xnode,
SerializationContext serializationContext)
Serializes a root node into XNode tree.
|
String |
write(XNode xnode,
QName rootElementName,
SerializationContext serializationContext)
Serializes a non-root node into XNode tree.
|
Element |
writeXRootToElement(RootXNode xroot) |
public static final Trace LOGGER
public DomLexicalProcessor(SchemaRegistry schemaRegistry)
@Deprecated public XNode read(File file, ParsingContext parsingContext) throws SchemaException, IOException
SchemaException
IOException
@NotNull public RootXNode read(@NotNull ParserSource source, @NotNull ParsingContext parsingContext) throws SchemaException, IOException
read
in interface LexicalProcessor<String>
SchemaException
IOException
@NotNull public List<RootXNode> readObjects(ParserSource source, ParsingContext parsingContext) throws SchemaException, IOException
readObjects
in interface LexicalProcessor<String>
SchemaException
IOException
@NotNull public RootXNode read(Document document) throws SchemaException
SchemaException
@NotNull public RootXNode read(Element rootElement) throws SchemaException
SchemaException
public RootXNode parseElementAsRoot(Element element) throws SchemaException
SchemaException
public MapXNode parseElementAsMap(Element element) throws SchemaException
SchemaException
@Nullable public XNode parseElementContent(Element element) throws SchemaException
SchemaException
public boolean canRead(@NotNull File file) throws IOException
LexicalProcessor
canRead
in interface LexicalProcessor<String>
IOException
public boolean canRead(@NotNull String dataString)
LexicalProcessor
canRead
in interface LexicalProcessor<String>
@NotNull public String write(@NotNull XNode xnode, @NotNull QName rootElementName, SerializationContext serializationContext) throws SchemaException
LexicalProcessor
write
in interface LexicalProcessor<String>
SchemaException
@NotNull public String write(@NotNull RootXNode xnode, SerializationContext serializationContext) throws SchemaException
LexicalProcessor
write
in interface LexicalProcessor<String>
SchemaException
public Element serializeUnderElement(XNode xnode, QName rootElementName, Element parentElement) throws SchemaException
SchemaException
public Element serializeXMapToElement(MapXNode xmap, QName elementName) throws SchemaException
SchemaException
@NotNull public Element writeXRootToElement(@NotNull RootXNode xroot) throws SchemaException
SchemaException
public Element serializeSingleElementMapToElement(MapXNode xmap) throws SchemaException
SchemaException
Copyright © 2016 Evolveum. All rights reserved.