go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
Data Structures | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
xoutlibrary::xoutbase< charT, traits > Class Template Reference

#include <xoutbase.h>

Detailed Description

template<class charT, class traits = char_traits< charT >>
class xoutlibrary::xoutbase< charT, traits >

Base class for xout.

An abstract base class, which defines the interface for using xout.

Definition at line 47 of file xoutbase.h.

Inheritance diagram for xoutlibrary::xoutbase< charT, traits >:
Inheritance graph
[legend]

Data Structures

class  Send
 

Public Types

typedef charT char_type
 
typedef CStreamMapType::value_type CStreamMapEntryType
 
typedef CStreamMapType::iterator CStreamMapIteratorType
 
typedef std::map< std::string, ostream_type * > CStreamMapType
 
typedef traits::int_type int_type
 
typedef basic_ios< charT, traits > ios_type
 
typedef traits::off_type off_type
 
typedef basic_ostream< charT, traits > ostream_type
 
typedef traits::pos_type pos_type
 
typedef xoutbase Self
 
typedef traits traits_type
 
typedef XStreamMapType::value_type XStreamMapEntryType
 
typedef XStreamMapType::iterator XStreamMapIteratorType
 
typedef std::map< std::string, Self * > XStreamMapType
 

Public Member Functions

virtual int AddOutput (const char *name, ostream_type *output)
 
virtual int AddOutput (const char *name, Self *output)
 
virtual int AddTargetCell (const char *name, ostream_type *cell)
 
virtual int AddTargetCell (const char *name, Self *cell)
 
virtual int AddTargetCell (const char *)
 
virtual const CStreamMapTypeGetCOutputs (void)
 
virtual const XStreamMapTypeGetXOutputs (void)
 
template<class T >
Selfoperator<< (const T &_arg)
 
Selfoperator<< (ostream_type &(*pf)(ostream_type &))
 
Selfoperator<< (ios_type &(*pf)(ios_type &))
 
Selfoperator<< (ios_base &(*pf)(ios_base &))
 
Selfoperator[] (const char *cellname)
 
virtual int RemoveOutput (const char *name)
 
virtual int RemoveTargetCell (const char *name)
 
virtual void SetOutputs (const CStreamMapType &outputmap)
 
virtual void SetOutputs (const XStreamMapType &outputmap)
 
virtual void SetTargetCells (const CStreamMapType &cellmap)
 
virtual void SetTargetCells (const XStreamMapType &cellmap)
 
virtual void WriteBufferedData (void)
 
 xoutbase ()
 
virtual ~xoutbase ()
 

Protected Member Functions

virtual void Callback (void)
 
virtual SelfSelectXCell (const char *name)
 
template<class T >
SelfSendToTargets (const T &_arg)
 

Protected Attributes

bool m_Call
 
CStreamMapType m_COutputs
 
CStreamMapType m_CTargetCells
 
XStreamMapType m_XOutputs
 
XStreamMapType m_XTargetCells
 

Member Typedef Documentation

template<class charT , class traits = char_traits< charT >>
typedef charT xoutlibrary::xoutbase< charT, traits >::char_type

Definition at line 55 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef CStreamMapType::value_type xoutlibrary::xoutbase< charT, traits >::CStreamMapEntryType

Definition at line 66 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef CStreamMapType::iterator xoutlibrary::xoutbase< charT, traits >::CStreamMapIteratorType

Definition at line 64 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef std::map< std::string, ostream_type * > xoutlibrary::xoutbase< charT, traits >::CStreamMapType

Definition at line 62 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef traits::int_type xoutlibrary::xoutbase< charT, traits >::int_type

Definition at line 56 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef basic_ios< charT, traits > xoutlibrary::xoutbase< charT, traits >::ios_type

Definition at line 60 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef traits::off_type xoutlibrary::xoutbase< charT, traits >::off_type

Definition at line 58 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef basic_ostream< charT, traits > xoutlibrary::xoutbase< charT, traits >::ostream_type

Definition at line 59 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef traits::pos_type xoutlibrary::xoutbase< charT, traits >::pos_type

Definition at line 57 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef xoutbase xoutlibrary::xoutbase< charT, traits >::Self

Typedef's.

Definition at line 52 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef traits xoutlibrary::xoutbase< charT, traits >::traits_type

Definition at line 54 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef XStreamMapType::value_type xoutlibrary::xoutbase< charT, traits >::XStreamMapEntryType

Definition at line 67 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef XStreamMapType::iterator xoutlibrary::xoutbase< charT, traits >::XStreamMapIteratorType

Definition at line 65 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
typedef std::map< std::string, Self * > xoutlibrary::xoutbase< charT, traits >::XStreamMapType

Definition at line 63 of file xoutbase.h.

Constructor & Destructor Documentation

template<class charT , class traits = char_traits< charT >>
xoutlibrary::xoutbase< charT, traits >::xoutbase ( )

Constructors

template<class charT , class traits = char_traits< charT >>
virtual xoutlibrary::xoutbase< charT, traits >::~xoutbase ( )
virtual

Destructor

Member Function Documentation

template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::AddOutput ( const char *  name,
ostream_type output 
)
virtual

Add/Remove an output stream (like cout, or an fstream, or an xout-object).

Reimplemented in xoutlibrary::xoutrow< charT, traits >, and xoutlibrary::xoutsimple< charT, traits >.

template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::AddOutput ( const char *  name,
Self output 
)
virtual
template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::AddTargetCell ( const char *  name,
ostream_type cell 
)
virtual

Methods to Add and Remove target cells. They return 0 when successful.

template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::AddTargetCell ( const char *  name,
Self cell 
)
virtual
template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::AddTargetCell ( const char *  )
inlinevirtual

Reimplemented in xoutlibrary::xoutrow< charT, traits >.

Definition at line 127 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
virtual void xoutlibrary::xoutbase< charT, traits >::Callback ( void  )
inlineprotectedvirtual

Called each time << is used, but only when m_Call == true;

Definition at line 169 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
virtual const CStreamMapType& xoutlibrary::xoutbase< charT, traits >::GetCOutputs ( void  )
virtual

Get the output maps.

Reimplemented in xoutlibrary::xoutsimple< charT, traits >.

template<class charT , class traits = char_traits< charT >>
virtual const XStreamMapType& xoutlibrary::xoutbase< charT, traits >::GetXOutputs ( void  )
virtual
template<class charT , class traits = char_traits< charT >>
template<class T >
Self& xoutlibrary::xoutbase< charT, traits >::operator<< ( const T &  _arg)
inline

the << operator. A templated member function, and some overloads.

The overloads are required for manipulators, like std::endl. (these manipulators in fact are global template functions, and need to deduce their own template arguments) template < class T > Self & operator<<(T & _arg) { return this->SendToTargets(_arg); }

Definition at line 94 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
Self& xoutlibrary::xoutbase< charT, traits >::operator<< ( ostream_type &(*)(ostream_type &)  pf)
inline

Definition at line 100 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
Self& xoutlibrary::xoutbase< charT, traits >::operator<< ( ios_type &(*)(ios_type &)  pf)
inline

Definition at line 106 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
Self& xoutlibrary::xoutbase< charT, traits >::operator<< ( ios_base &(*)(ios_base &)  pf)
inline

Definition at line 112 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
Self& xoutlibrary::xoutbase< charT, traits >::operator[] ( const char *  cellname)
inline

The operator [] simply calls this->SelectXCell(cellname). It returns an x-cell

template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::RemoveOutput ( const char *  name)
virtual
template<class charT , class traits = char_traits< charT >>
virtual int xoutlibrary::xoutbase< charT, traits >::RemoveTargetCell ( const char *  name)
virtual
template<class charT , class traits = char_traits< charT >>
virtual Self& xoutlibrary::xoutbase< charT, traits >::SelectXCell ( const char *  name)
protectedvirtual

Returns a target cell.

Reimplemented in xoutlibrary::xoutrow< charT, traits >.

template<class charT , class traits = char_traits< charT >>
template<class T >
Self& xoutlibrary::xoutbase< charT, traits >::SendToTargets ( const T &  _arg)
inlineprotected

Definition at line 172 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
virtual void xoutlibrary::xoutbase< charT, traits >::SetOutputs ( const CStreamMapType outputmap)
virtual
template<class charT , class traits = char_traits< charT >>
virtual void xoutlibrary::xoutbase< charT, traits >::SetOutputs ( const XStreamMapType outputmap)
virtual
template<class charT , class traits = char_traits< charT >>
virtual void xoutlibrary::xoutbase< charT, traits >::SetTargetCells ( const CStreamMapType cellmap)
virtual
template<class charT , class traits = char_traits< charT >>
virtual void xoutlibrary::xoutbase< charT, traits >::SetTargetCells ( const XStreamMapType cellmap)
virtual
template<class charT , class traits = char_traits< charT >>
virtual void xoutlibrary::xoutbase< charT, traits >::WriteBufferedData ( void  )
virtual

Field Documentation

template<class charT , class traits = char_traits< charT >>
bool xoutlibrary::xoutbase< charT, traits >::m_Call
protected

Boolean that says whether the Callback-function must be called. False by default.

Definition at line 166 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
CStreamMapType xoutlibrary::xoutbase< charT, traits >::m_COutputs
protected

Maps that contain the outputs.

Definition at line 156 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
CStreamMapType xoutlibrary::xoutbase< charT, traits >::m_CTargetCells
protected

Maps that contain the target cells. The << operator passes its input to these maps.

Definition at line 161 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
XStreamMapType xoutlibrary::xoutbase< charT, traits >::m_XOutputs
protected

Definition at line 157 of file xoutbase.h.

template<class charT , class traits = char_traits< charT >>
XStreamMapType xoutlibrary::xoutbase< charT, traits >::m_XTargetCells
protected

Definition at line 162 of file xoutbase.h.



Generated on 04-09-2015 for elastix by doxygen 1.8.9.1 elastix logo