#include <source/toolbox/base/ParallelBuffer.h>
Public Member Functions | |
ParallelBuffer () | |
virtual | ~ParallelBuffer () |
void | setActive (bool active) |
void | setPrefixString (const string &text) |
void | setOutputStream1 (ostream *stream) |
void | setOutputStream2 (ostream *stream) |
void | outputString (const string &text) |
void | outputString (const string &text, const int length) |
virtual int | sync () |
virtual int | overflow (int ch) |
|
Create a parallel buffer class. The object will require further initialization to set up the I/O streams and prefix string. |
|
The destructor simply deallocates any internal data buffers. It does not modify the output streams. |
|
Set whether the output stream will be active. If the parallel buffer stream is disabled, then no data is forwarded to the output streams. The internal data buffer is deallocated and pointers are reset whenever the parallel buffer is deactivated. |
|
Set the prefix that begins every new line to the output stream. A sample prefix is "P=XXXXX: ", where XXXXX represents the node number. |
|
Set the primary output stream. If not NULL, then output data is sent to this stream. The primary output stream is typically stderr or stdout or perhaps a log file. |
|
Set the secondary output stream. If not NULL, then output data is sent to this stream. The secondary output stream is typically NULL or a log file that mirrors the primary output stream. |
|
Write a text string to the output stream. Note that the string is not actually written until an end-of-line is detected. |
|
Write a text string of the specified length to the output file. Note that the string is not actually written until an end-of-line is detected. |
|
Synchronize the parallel buffer (called from streambuf). |
|
Write an overflow character into the parallel buffer (called from streambuf). |