Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

MultiplexStreamBuf Class Reference

#include <multiplexStreamBuf.h>

List of all members.

Public Types

enum  BufferType { BT_none, BT_line }
enum  OutputType { OT_ostream, OT_stdio, OT_system_debug }

Public Member Functions

 MultiplexStreamBuf ()
virtual ~MultiplexStreamBuf ()
void add_output (BufferType buffer_type, OutputType output_type, ostream *out=(ostream *) NULL, FILE *fout=(FILE *) NULL, bool owns_obj=false)
void flush ()

Protected Member Functions

virtual int overflow (int c)
virtual int sync ()

Private Types

typedef pvector< OutputOutputs

Private Member Functions

void write_chars (const char *start, int length, bool flush)

Private Attributes

Outputs _outputs
string _line_buffer


Member Typedef Documentation

typedef pvector<Output> MultiplexStreamBuf::Outputs [private]
 

Definition at line 80 of file multiplexStreamBuf.h.


Member Enumeration Documentation

enum MultiplexStreamBuf::BufferType
 

Enumeration values:
BT_none 
BT_line 

Definition at line 42 of file multiplexStreamBuf.h.

enum MultiplexStreamBuf::OutputType
 

Enumeration values:
OT_ostream 
OT_stdio 
OT_system_debug 

Definition at line 47 of file multiplexStreamBuf.h.


Constructor & Destructor Documentation

MultiplexStreamBuf::MultiplexStreamBuf  ) 
 

Definition at line 97 of file multiplexStreamBuf.cxx.

MultiplexStreamBuf::~MultiplexStreamBuf  )  [virtual]
 

Definition at line 111 of file multiplexStreamBuf.cxx.

References _outputs, MultiplexStreamBuf::Output::close(), and sync().


Member Function Documentation

void MultiplexStreamBuf::add_output BufferType  buffer_type,
OutputType  output_type,
ostream *  out = (ostream *) NULL,
FILE *  fout = (FILE *) NULL,
bool  owns_obj = false
 

Definition at line 130 of file multiplexStreamBuf.cxx.

References MultiplexStreamBuf::Output::_buffer_type, MultiplexStreamBuf::Output::_fout, MultiplexStreamBuf::Output::_out, MultiplexStreamBuf::Output::_output_type, _outputs, and MultiplexStreamBuf::Output::_owns_obj.

void MultiplexStreamBuf::flush  ) 
 

Definition at line 155 of file multiplexStreamBuf.cxx.

References write_chars().

int MultiplexStreamBuf::overflow int  c  )  [protected, virtual]
 

Definition at line 170 of file multiplexStreamBuf.cxx.

References c, n, streamsize, and write_chars().

int MultiplexStreamBuf::sync  )  [protected, virtual]
 

Definition at line 199 of file multiplexStreamBuf.cxx.

References n, streamsize, and write_chars().

Referenced by ~MultiplexStreamBuf().

void MultiplexStreamBuf::write_chars const char *  start,
int  length,
bool  flush
[private]
 

Definition at line 229 of file multiplexStreamBuf.cxx.

References MultiplexStreamBuf::Output::_buffer_type, _line_buffer, _outputs, BT_line, BT_none, length, start, and MultiplexStreamBuf::Output::write_string().

Referenced by flush(), overflow(), and sync().


Member Data Documentation

string MultiplexStreamBuf::_line_buffer [private]
 

Definition at line 83 of file multiplexStreamBuf.h.

Referenced by write_chars().

Outputs MultiplexStreamBuf::_outputs [private]
 

Definition at line 81 of file multiplexStreamBuf.h.

Referenced by add_output(), write_chars(), and ~MultiplexStreamBuf().


The documentation for this class was generated from the following files:
Generated on Fri Apr 18 00:12:49 2003 for Panda by doxygen1.3