public static interface XmlGenerator.ElementGenerator
Element to an XmlWriter.
The generic implementation of this interface is provided by the
XmlGenerator.XmlElementGenerator class, but it may be overridden by element
types that want to take more direct control over XML output for a given
element.
| Modifier and Type | Method and Description |
|---|---|
void |
endElement(XmlWriter xw,
Element e,
ElementMetadata<?,?> metadata)
End an element, writing a close tag if needed.
|
boolean |
startElement(XmlWriter xw,
Element parent,
Element e,
ElementMetadata<?,?> metadata)
Start an element.
|
void |
textContent(XmlWriter xw,
Element e,
ElementMetadata<?,?> metadata)
Write the text content for an element.
|
boolean startElement(XmlWriter xw, Element parent, Element e, ElementMetadata<?,?> metadata) throws IOException
false to indicate that textContent
and child elements should not be added.xw - the xml writer to write to.parent - the parent element.e - the element to start.metadata - the metadata for the elementIOException - if an error occurs while writing to the writer.void textContent(XmlWriter xw, Element e, ElementMetadata<?,?> metadata) throws IOException
IOExceptionvoid endElement(XmlWriter xw, Element e, ElementMetadata<?,?> metadata) throws IOException
IOExceptionCopyright © 2012. All Rights Reserved.