rwsf::XmlStringWriterrwsf::XmlWriter
flush() getBufferLength() |
getLength() getString() |
resize() writeToSink() |
XmlStringWriter() ~XmlStringWriter() |
#include rwsf/core/XmlStringWriter.h
Class rwsf::XmlStringWriter implements an rwsf::XmlWriter that uses an std::string as a data sink. This class provides a string buffer based implementation of the rwsf::XmlWriter interface to aid in writing XML content to a string.
The class inherits most functions from rwsf::XmlWriter.
XmlStringWriter(size_t capacity = RWSF_STR_WRITER_BUFFER_SIZE);
Default constructor. Constructs an rwsf::XmlStringWriter that contains an empty std::string. The initial capacity of the underlying buffer is set to capacity. The default capacity is 4096.
virtual ~XmlStringWriter();
Destructor.
void flush();
Implements method in rwsf::XmlWriter
Base class documentation:
Pure virtual function. In a derived class, this function flushes the underlying data sink. The behavior of the function depends on the type of the data sink.
Implementation documentation:
Ensures any buffered data has been written.
size_t getBufferLength() const;
Returns the length of the buffer.
size_t getLength() const;
Returns the length of the std::string this object contains.
std::string getString() const;
Returns the std::string this object contains.
void resize(size_t);
Resizes this rwsf::XmlStringWriter object, allowing for the resize of the buffer.
void writeToSink(const std::string &);
Reimplements method in rwsf::XmlWriter
Base class documentation:
Pure virtual function. In a derived class, this function writes the contents of text to the underlying data sink.
void writeToSink(const char *, size_t);
Implements method in rwsf::XmlWriter
Base class documentation:
Pure virtual function. In a derived class, this function writes the contents of str limited to the length of len to the underlying data sink.
void writeToSink(char);
Implements method in rwsf::XmlWriter
Base class documentation:
Pure virtual function. In a derived class, this function writes c to the underlying data sink.
© Copyright Rogue Wave Software, Inc. All Rights Reserved. All Rights Reserved. Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. HydraExpress is a trademark of Rogue Wave Software, Inc. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.