libROM  v1.0
Data-driven physical simulation library
 All Classes Functions Variables Enumerations
Public Member Functions | List of all members
CAROM::ParallelBuffer Class Reference

#include <ParallelBuffer.h>

Inheritance diagram for CAROM::ParallelBuffer:

Public Member Functions

 ParallelBuffer ()
 Default constructor. More...
 
 ~ParallelBuffer ()
 Destructor. More...
 
void outputString (const std::string &text)
 Write a text string to the output stream. More...
 
void outputString (const std::string &text, int length)
 Write a text string of the specified length to the output file. More...
 
int sync ()
 Synchronize the parallel buffer (called from streambuf). More...
 
int overflow (int ch)
 Write an overflow character into the parallel buffer (called from streambuf). More...
 

Detailed Description

Class ParallelBuffer is a simple I/O stream utility that intercepts output from an ostream and redirects the output as necessary for parallel I/O. This class defines a stream buffer class for an ostream class.

Constructor & Destructor Documentation

CAROM::ParallelBuffer::ParallelBuffer ( )

Default constructor.

The object will require further initialization to set up the I/O streams and prefix string.

CAROM::ParallelBuffer::~ParallelBuffer ( )

Destructor.

Simply deallocates any internal data buffers. It does not modify the output streams.

Member Function Documentation

void CAROM::ParallelBuffer::outputString ( const std::string &  text)
inline

Write a text string to the output stream.

Note that the string is not actually written until an end-of-line is detected.

Parameters
[in]textThe string to be written.
void CAROM::ParallelBuffer::outputString ( const std::string &  text,
int  length 
)

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.

Parameters
[in]textThe string to be written.
[in]lengthThe length of the string.
int CAROM::ParallelBuffer::overflow ( int  ch)

Write an overflow character into the parallel buffer (called from streambuf).

Parameters
[in]chThe character to write.
Returns
0
int CAROM::ParallelBuffer::sync ( )

Synchronize the parallel buffer (called from streambuf).

Returns
0

The documentation for this class was generated from the following file: