$search

rtc::OutputHandler Class Reference

#include <rtcOutputHandler.h>

Inheritance diagram for rtc::OutputHandler:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual bool binary () const =0
 returns if the data format is binary or ascii
bool good () const
 Check if the state of the stream is good for i/o operations.
 OutputHandler (std::ostream &os)
 construct from ostream
 OutputHandler ()
 default constructor
std::ostream & stream ()
 Returns a reference to the stream.
virtual void use (std::ostream &os)
 indicate the output stream to be used
virtual bool writeEOL ()=0
 write the EOL symbol
virtual bool writeName (const std::string &name)=0
 write the name of a name-data pair
virtual bool writeSeparator ()=0
 write the separator of a name-data pair
virtual ~OutputHandler ()
 destructor

virtual bool write (const char *data, long n)=0
virtual bool write (const unsigned short &data)=0
virtual bool write (const short &data)=0
virtual bool write (const unsigned long &data)=0
virtual bool write (const long &data)=0
virtual bool write (const bool &data)=0
virtual bool write (const unsigned char &data)=0
virtual bool write (const char &data)=0
virtual bool write (const unsigned int &data)=0
virtual bool write (const int &data)=0
virtual bool write (const float &data)=0
virtual bool write (const double &data)=0
virtual bool write (const std::string &data)=0

Protected Attributes

std::ostream * outStream
 pointer to the input stream

Detailed Description

Base output handler class.

The output handler classes offer an abstract interface for the IOObject classes to write() them in different formats.

All OutputHandlers are used as wrappers for std::ostream objects. Therefore, the abstract interface provides the virtual methods use() to indicate which stream has to be used.

Definition at line 40 of file rtcOutputHandler.h.


Constructor & Destructor Documentation

rtc::OutputHandler::OutputHandler (  ) 

default constructor

Definition at line 29 of file rtcOutputHandler.cpp.

rtc::OutputHandler::OutputHandler ( std::ostream &  os  ) 

construct from ostream

Definition at line 35 of file rtcOutputHandler.cpp.

rtc::OutputHandler::~OutputHandler (  )  [virtual]

destructor

Definition at line 41 of file rtcOutputHandler.cpp.


Member Function Documentation

virtual bool rtc::OutputHandler::binary (  )  const [pure virtual]

returns if the data format is binary or ascii

Implemented in rtc::ASCIIOutputHandler, and rtc::BinaryOutputHandler.

bool rtc::OutputHandler::good (  )  const

Check if the state of the stream is good for i/o operations.

Definition at line 58 of file rtcOutputHandler.cpp.

std::ostream & rtc::OutputHandler::stream (  ) 

Returns a reference to the stream.

returns a reference to the stream

Definition at line 52 of file rtcOutputHandler.cpp.

void rtc::OutputHandler::use ( std::ostream &  os  )  [virtual]

indicate the output stream to be used

Definition at line 46 of file rtcOutputHandler.cpp.

virtual bool rtc::OutputHandler::write ( const char *  data,
long  n 
) [pure virtual]
virtual bool rtc::OutputHandler::write ( const unsigned short &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const short &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const unsigned long &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const long &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const bool &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const unsigned char &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const char &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const unsigned int &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const int &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const float &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const double &  data  )  [pure virtual]
virtual bool rtc::OutputHandler::write ( const std::string &  data  )  [pure virtual]

write members for data

Implemented in rtc::ASCIIOutputHandler, and rtc::BinaryOutputHandler.

virtual bool rtc::OutputHandler::writeEOL (  )  [pure virtual]

write the EOL symbol

Implemented in rtc::ASCIIOutputHandler, and rtc::BinaryOutputHandler.

virtual bool rtc::OutputHandler::writeName ( const std::string &  name  )  [pure virtual]

write the name of a name-data pair

Implemented in rtc::ASCIIOutputHandler, and rtc::BinaryOutputHandler.

virtual bool rtc::OutputHandler::writeSeparator (  )  [pure virtual]

write the separator of a name-data pair

Implemented in rtc::ASCIIOutputHandler, and rtc::BinaryOutputHandler.


Member Data Documentation

std::ostream* rtc::OutputHandler::outStream [protected]

pointer to the input stream

Definition at line 82 of file rtcOutputHandler.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


rtc
Author(s): Benjamin Pitzer
autogenerated on Sun Mar 3 11:08:32 2013