Om
1.0.0
A universal framework for multimedia simulation
|
A class that abstracts a destination for a stream of character information. More...
#include <omStringOutputStream.h>
Public Member Functions | |
StringOutputStream () | |
Create a StringOutputStream with the native output endianness. More... | |
StringOutputStream (data::Endianness newEndianness) | |
Create a StringOutputStream with the specified output endianness. More... | |
virtual | ~StringOutputStream () |
Destroy an output stream and free all of it's resources (close it). More... | |
Bool | writeASCII (Char character) |
Write one ASCII character to the output stream. More... | |
Size | writeASCII (const Char *characters) |
Write characters from the buffer until a NULl terminator is reached and return the number written. More... | |
Size | writeASCII (const Char *characters, Size numCharacters) |
Write the specified number of characters from the buffer and return the number written. More... | |
Size | writeASCII (const data::String &string) |
Write the specified string to the output string and return the number of characters written. More... | |
Bool | writeUTF8 (UTF8Char character) |
Write one UTF-8 character to the output stream. More... | |
Size | writeUTF8 (const UTF8Char *characters) |
Write characters from the buffer until a NULl terminator is reached and return the number written. More... | |
Size | writeUTF8 (const UTF8Char *characters, Size numCharacters) |
Write the specified number of characters from the buffer and return the number written. More... | |
Size | writeUTF8 (const data::UTF8String &string) |
Write the specified string to the output string and return the number of characters written. More... | |
Bool | writeUTF16 (UTF16Char character) |
Write one UTF-16 character to the output stream. More... | |
Size | writeUTF16 (const UTF16Char *characters) |
Write characters from the buffer until a NULL terminator is reached and return the number written. More... | |
Size | writeUTF16 (const UTF16Char *characters, Size numCharacters) |
Write the specified number of characters from the buffer and return the number written. More... | |
Size | writeUTF16 (const data::UTF16String &string) |
Write the specified string to the output string and return the number of characters written. More... | |
Bool | writeUTF32 (UTF32Char character) |
Write one UTF-32 character to the output stream. More... | |
Size | writeUTF32 (const UTF32Char *characters) |
Write characters from the buffer until a NULl terminator is reached and return the number written. More... | |
Size | writeUTF32 (const UTF32Char *characters, Size numCharacters) |
Write the specified number of characters from the buffer and return the number written. More... | |
Size | writeUTF32 (const data::UTF32String &string) |
Write the specified string to the output string and return the number of characters written. More... | |
virtual void | flush ()=0 |
Flush the output stream, sending all internally buffered output to it's destination. More... | |
data::Endianness | getEndianness () const |
Get the current endianness of the wide characters being written to the stream. More... | |
void | setEndianness (data::Endianness newEndianness) |
Set the stream to write wide characters in the specified endian format. More... | |
Protected Member Functions | |
virtual Size | writeChars (const Char *characters, Size number)=0 |
Write the specified number of characters from the character buffer and return the number written. More... | |
virtual Size | writeUTF8Chars (const UTF8Char *characters, Size number)=0 |
Write the specified number of UTF-8 characters from the character buffer and return the number written. More... | |
virtual Size | writeUTF16Chars (const UTF16Char *characters, Size number)=0 |
Write the specified number of UTF-16 characters from the character buffer and return the number written. More... | |
virtual Size | writeUTF32Chars (const UTF32Char *characters, Size number)=0 |
Write the specified number of UTF-32 characters from the character buffer and return the number written. More... | |
A class that abstracts a destination for a stream of character information.
|
inline |
Create a StringOutputStream with the native output endianness.
|
inline |
Create a StringOutputStream with the specified output endianness.
|
inlinevirtual |
Destroy an output stream and free all of it's resources (close it).
Write one ASCII character to the output stream.
Write characters from the buffer until a NULl terminator is reached and return the number written.
Write the specified number of characters from the buffer and return the number written.
|
inline |
Write the specified string to the output string and return the number of characters written.
Write one UTF-8 character to the output stream.
Write characters from the buffer until a NULl terminator is reached and return the number written.
|
inline |
Write the specified number of characters from the buffer and return the number written.
|
inline |
Write the specified string to the output string and return the number of characters written.
Write one UTF-16 character to the output stream.
Write characters from the buffer until a NULL terminator is reached and return the number written.
|
inline |
Write the specified number of characters from the buffer and return the number written.
|
inline |
Write the specified string to the output string and return the number of characters written.
Write one UTF-32 character to the output stream.
Write characters from the buffer until a NULl terminator is reached and return the number written.
|
inline |
Write the specified number of characters from the buffer and return the number written.
|
inline |
Write the specified string to the output string and return the number of characters written.
|
pure virtual |
Flush the output stream, sending all internally buffered output to it's destination.
This method causes all currently pending output data to be sent to it's final destination. This method ensures that this is done and that all internal data buffers are emptied if they have any contents.
Implemented in om::io::Log, om::io::FileWriter, and om::io::PrintStream.
|
inline |
Get the current endianness of the wide characters being written to the stream.
|
inline |
Set the stream to write wide characters in the specified endian format.
|
protectedpure virtual |
Write the specified number of characters from the character buffer and return the number written.
Implemented in om::io::FileWriter, and om::io::PrintStream.
|
protectedpure virtual |
Write the specified number of UTF-8 characters from the character buffer and return the number written.
Implemented in om::io::FileWriter, and om::io::PrintStream.
|
protectedpure virtual |
Write the specified number of UTF-16 characters from the character buffer and return the number written.
Implemented in om::io::FileWriter, and om::io::PrintStream.
|
protectedpure virtual |
Write the specified number of UTF-32 characters from the character buffer and return the number written.
Implemented in om::io::FileWriter, and om::io::PrintStream.