org.deegree.junit
Class XMLMemoryStreamWriter
java.lang.Object
org.deegree.junit.XMLMemoryStreamWriter
public class XMLMemoryStreamWriter
- extends Object
This class creates a XMLStreamWriter
that writes into a temporary buffer and can create a Reader
on
that buffer. The toString()
method allows to print the content conveniently.
NOTE: This class is not thread-safe!
- Version:
- $Revision: 30117 $, $Date: 2011-03-22 09:24:16 +0100 (Tue, 22 Mar 2011) $
- Author:
- Oliver Tonnhofer, last edited by: $Author: aschmitz $
XMLMemoryStreamWriter
public XMLMemoryStreamWriter()
getXMLStreamWriter
public XMLStreamWriter getXMLStreamWriter()
- Create a
XMLStreamWriter
that writes into a buffer. Call getReader()
to close the writer and get
a Reader
on the buffer.
- Returns:
- the XMLStreamWriter
getReader
public Reader getReader()
- Get a reader for the xml buffer. This will close the
XMLStreamWriter
.
- Returns:
- a
Reader
for the buffer
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2011. All Rights Reserved.