Search in sources :

Example 1 with StaxWriter

use of com.thoughtworks.xstream.io.xml.StaxWriter in project camel by apache.

the class XStreamDataFormat method createHierarchicalStreamWriter.

protected HierarchicalStreamWriter createHierarchicalStreamWriter(Exchange exchange, Object body, OutputStream stream) throws XMLStreamException {
    updateCharactorEncodingInfo(exchange);
    if (getXstreamDriver() != null) {
        return getXstreamDriver().createWriter(stream);
    }
    XMLStreamWriter xmlWriter = getStaxConverter().createXMLStreamWriter(stream, exchange);
    return new StaxWriter(new QNameMap(), xmlWriter);
}
Also used : XMLStreamWriter(javax.xml.stream.XMLStreamWriter) StaxWriter(com.thoughtworks.xstream.io.xml.StaxWriter) QNameMap(com.thoughtworks.xstream.io.xml.QNameMap)

Aggregations

QNameMap (com.thoughtworks.xstream.io.xml.QNameMap)1 StaxWriter (com.thoughtworks.xstream.io.xml.StaxWriter)1 XMLStreamWriter (javax.xml.stream.XMLStreamWriter)1