Package org.codehaus.jettison
Class AbstractXMLEventWriter
- java.lang.Object
-
- org.codehaus.jettison.AbstractXMLEventWriter
-
- All Implemented Interfaces:
XMLEventConsumer
,XMLEventWriter
public class AbstractXMLEventWriter extends Object implements XMLEventWriter
An XMLEventWriter that delegates to an XMLStreamWriter.- Since:
- 21-Mar-2008
- Author:
- Thomas.Diesler@jboss.com
-
-
Constructor Summary
Constructors Constructor Description AbstractXMLEventWriter(XMLStreamWriter streamWriter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(XMLEvent event)
void
add(XMLEventReader eventReader)
void
close()
void
flush()
NamespaceContext
getNamespaceContext()
String
getPrefix(String prefix)
void
setDefaultNamespace(String namespace)
void
setNamespaceContext(NamespaceContext nsContext)
void
setPrefix(String prefix, String uri)
-
-
-
Constructor Detail
-
AbstractXMLEventWriter
public AbstractXMLEventWriter(XMLStreamWriter streamWriter)
-
-
Method Detail
-
add
public void add(XMLEvent event) throws XMLStreamException
- Specified by:
add
in interfaceXMLEventConsumer
- Specified by:
add
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
add
public void add(XMLEventReader eventReader) throws XMLStreamException
- Specified by:
add
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
close
public void close() throws XMLStreamException
- Specified by:
close
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
flush
public void flush() throws XMLStreamException
- Specified by:
flush
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
getNamespaceContext
public NamespaceContext getNamespaceContext()
- Specified by:
getNamespaceContext
in interfaceXMLEventWriter
-
getPrefix
public String getPrefix(String prefix) throws XMLStreamException
- Specified by:
getPrefix
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
setDefaultNamespace
public void setDefaultNamespace(String namespace) throws XMLStreamException
- Specified by:
setDefaultNamespace
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
setNamespaceContext
public void setNamespaceContext(NamespaceContext nsContext) throws XMLStreamException
- Specified by:
setNamespaceContext
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
setPrefix
public void setPrefix(String prefix, String uri) throws XMLStreamException
- Specified by:
setPrefix
in interfaceXMLEventWriter
- Throws:
XMLStreamException
-
-