public class XMLStreamReaderToXMLStreamWriter extends Object
XMLStreamReader
and writes to XMLStreamWriter
as-is.
This class can be sub-classed to implement a simple transformation logic.
Modifier and Type | Field and Description |
---|---|
protected XMLStreamReader |
in
Deprecated.
|
protected XMLStreamWriter |
out
Deprecated.
|
Constructor and Description |
---|
XMLStreamReaderToXMLStreamWriter()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
void |
bridge(XMLStreamReader in,
XMLStreamWriter out)
Deprecated.
Reads one subtree and writes it out.
|
protected void |
handleAttribute(int i)
Deprecated.
Writes out the
i -th attribute of the current element. |
protected void |
handleCDATA()
Deprecated.
|
protected void |
handleCharacters()
Deprecated.
|
protected void |
handleComment()
Deprecated.
|
protected void |
handleDTD()
Deprecated.
|
protected void |
handleEndElement()
Deprecated.
|
protected void |
handleEntityReference()
Deprecated.
|
protected void |
handlePI()
Deprecated.
|
protected void |
handleSpace()
Deprecated.
|
protected void |
handleStartElement()
Deprecated.
|
protected XMLStreamReader in
protected XMLStreamWriter out
public XMLStreamReaderToXMLStreamWriter()
public void bridge(XMLStreamReader in, XMLStreamWriter out) throws XMLStreamException
The XMLStreamWriter
never receives a start/end document event.
Those need to be written separately by the caller.
XMLStreamException
protected void handlePI() throws XMLStreamException
XMLStreamException
protected void handleCharacters() throws XMLStreamException
XMLStreamException
protected void handleEndElement() throws XMLStreamException
XMLStreamException
protected void handleStartElement() throws XMLStreamException
XMLStreamException
protected void handleAttribute(int i) throws XMLStreamException
i
-th attribute of the current element.
Used from handleStartElement()
.
XMLStreamException
protected void handleDTD() throws XMLStreamException
XMLStreamException
protected void handleComment() throws XMLStreamException
XMLStreamException
protected void handleEntityReference() throws XMLStreamException
XMLStreamException
protected void handleSpace() throws XMLStreamException
XMLStreamException
protected void handleCDATA() throws XMLStreamException
XMLStreamException
Copyright © 2015 Oracle Corporation. All rights reserved.