public class XMLEventWriterImpl extends Object implements XMLEventWriter
| Constructor and Description |
|---|
XMLEventWriterImpl(XMLStreamWriter streamWriter) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(XMLEvent xMLEvent) |
void |
add(XMLEventReader xMLEventReader) |
void |
close() |
void |
flush() |
NamespaceContext |
getNamespaceContext() |
String |
getPrefix(String namespaceURI) |
void |
setDefaultNamespace(String uri) |
void |
setNamespaceContext(NamespaceContext namespaceContext) |
void |
setPrefix(String prefix,
String uri) |
public XMLEventWriterImpl(XMLStreamWriter streamWriter)
streamWriter - public void add(XMLEventReader xMLEventReader) throws XMLStreamException
add in interface XMLEventWriterxMLEventReader - XMLStreamExceptionpublic void add(XMLEvent xMLEvent) throws XMLStreamException
add in interface XMLEventConsumeradd in interface XMLEventWriterxMLEvent - XMLStreamExceptionpublic void close()
throws XMLStreamException
close in interface XMLEventWriterXMLStreamExceptionpublic void flush()
throws XMLStreamException
flush in interface XMLEventWriterXMLStreamException - will inturn call flush on the stream to which data is being
written.public NamespaceContext getNamespaceContext()
getNamespaceContext in interface XMLEventWriterpublic String getPrefix(String namespaceURI) throws XMLStreamException
getPrefix in interface XMLEventWriternamespaceURI - Namespace URIXMLStreamExceptionpublic void setDefaultNamespace(String uri) throws XMLStreamException
setDefaultNamespace in interface XMLEventWriteruri - Namespace URIXMLStreamExceptionpublic void setNamespaceContext(NamespaceContext namespaceContext) throws XMLStreamException
setNamespaceContext in interface XMLEventWriternamespaceContext - Namespace ContextXMLStreamExceptionpublic void setPrefix(String prefix, String uri) throws XMLStreamException
setPrefix in interface XMLEventWriterprefix - namespace prefix associated with the uri.uri - Namespace URIXMLStreamExceptionCopyright © 2018–2021 mhoffrogge. All rights reserved.