#include <core_io_writer.h>

Public Member Functions | |
| CoreIOWriter (FILE *_outputBuffer, bool _isUnicode, LineEndingType _lnEnding=CC_LN_NATIVE) | |
| The constructor. | |
| virtual | ~CoreIOWriter () |
| The destructor. | |
| virtual bool | IsOpen () |
| Validates that the file buffer isn't NULL. | |
| virtual CrissCross::Errors | SetLineEndings (LineEndingType _ending) |
| Sets the line ending convention used by this CoreIOWriter instance. | |
| virtual CrissCross::Errors | Write (const char *_format,...) |
| Writes a string to the buffer. | |
| virtual CrissCross::Errors | Write (std::string &_string) |
| Writes a string to the buffer. | |
| virtual CrissCross::Errors | WriteLine () |
| Writes an empty line to the buffer. | |
| virtual CrissCross::Errors | WriteLine (const char *_format,...) |
| Writes a string to the buffer with a newline appended. | |
| virtual CrissCross::Errors | WriteLine (std::string &_string) |
| Writes a string to the buffer with a newline appended. | |
| void | Flush () |
| Flushes the output buffer. | |
Protected Attributes | |
| char | m_lineEnding [4] |
| Line ending buffer. | |
| FILE * | m_fileOutputPointer |
| Input/output FILE pointer. | |
| bool | m_unicode |
| Indicates whether the buffer is to be written in unicode or not. (UNIMPLEMENTED). | |
| CrissCross::System::Mutex | m_ioMutex |
| Thread-safe mutex. | |
A class inherited by most I/O classes, including Console and FileWriter.
| CoreIOWriter | ( | FILE * | _outputBuffer, | |
| bool | _isUnicode, | |||
| LineEndingType | _lnEnding = CC_LN_NATIVE | |||
| ) |
The constructor.
Creates a new CoreIOWriter instance. Will initialize line endings to the platform's default, also initializes CoreIOWriter::m_ioMutex.
| _outputBuffer | The buffer to be used for write operations. | |
| _isUnicode | The buffer is going to be a Unicode I/O buffer. (UNIMPLEMENTED) | |
| _lnEnding | The line ending to use. |
| virtual bool IsOpen | ( | ) | [virtual] |
Validates that the file buffer isn't NULL.
| virtual CrissCross::Errors SetLineEndings | ( | LineEndingType | _ending | ) | [virtual] |
Sets the line ending convention used by this CoreIOWriter instance.
| _ending | Any of the LineEndingType values. |
| virtual CrissCross::Errors Write | ( | std::string & | _string | ) | [virtual] |
Writes a string to the buffer.
| _string | The string to be written. |
| virtual CrissCross::Errors Write | ( | const char * | _format, | |
| ... | ||||
| ) | [virtual] |
Writes a string to the buffer.
| _format | The format of the string to be written. |
| virtual CrissCross::Errors WriteLine | ( | std::string & | _string | ) | [virtual] |
Writes a string to the buffer with a newline appended.
Prints the string to the buffer, and then prints the line terminator in the format specified by CoreIOWriter::m_lineEnding.
| _string | The std::string to write. |
| virtual CrissCross::Errors WriteLine | ( | const char * | _format, | |
| ... | ||||
| ) | [virtual] |
Writes a string to the buffer with a newline appended.
Prints the string to the buffer, and then prints the line terminator in the format specified by CoreIOWriter::m_lineEnding.
| _format | The format of the string to be written. |
| virtual CrissCross::Errors WriteLine | ( | ) | [virtual] |
Writes an empty line to the buffer.
Writes CoreIOWriter::m_lineEnding to the buffer.
CrissCross::System::Mutex m_ioMutex [protected] |
Thread-safe mutex.
Prevents more than one read or write from occurring simultaneously.
char m_lineEnding[4] [protected] |
Line ending buffer.
Stores the line ending selected by SetLineEndings.
1.5.8