go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
Public Types | Public Member Functions | Protected Member Functions | Private Attributes
xoutlibrary::xoutrow Class Reference

#include <xoutrow.h>

Detailed Description

The xoutrow class can easily generate tables.

The xoutrow class is used in elastix for printing the registration information, such as metric value, gradient information, etc. You can fill in all this information, and only after calling WriteBufferedData() the entire row is printed to the desired outputs.

Definition at line 42 of file xoutrow.h.

Inheritance diagram for xoutlibrary::xoutrow:
Inheritance graph

Public Types

using Self = xoutrow
using Superclass = xoutbase
- Public Types inherited from xoutlibrary::xoutbase
using CStreamMapEntryType = CStreamMapType::value_type
using CStreamMapType = std::map< std::string, std::ostream * >
using Self = xoutbase
using XStreamMapEntryType = XStreamMapType::value_type
using XStreamMapType = std::map< std::string, Self * >

Public Member Functions

int AddNewTargetCell (const char *name)
int AddOutput (const char *name, std::ostream *output) override
int AddOutput (const char *name, Superclass *output) override
int RemoveOutput (const char *name) override
int RemoveTargetCell (const char *name) override
void SetOutputs (const CStreamMapType &outputmap) override
void SetOutputs (const XStreamMapType &outputmap) override
void WriteBufferedData () override
virtual void WriteHeaders ()
 xoutrow ()=default
 ~xoutrow () override=default
- Public Member Functions inherited from xoutlibrary::xoutbase
virtual int AddOutput (const char *name, Self *output)
virtual int AddOutput (const char *name, std::ostream *output)
virtual int AddTargetCell (const char *name, Self *cell)
virtual int AddTargetCell (const char *name, std::ostream *cell)
virtual const CStreamMapTypeGetCOutputs ()
virtual const XStreamMapTypeGetXOutputs ()
template<class T >
Selfoperator<< (const T &_arg)
Selfoperator<< (std::ios &(*pf)(std::ios &))
Selfoperator<< (std::ios_base &(*pf)(std::ios_base &))
Selfoperator<< (std::ostream &(*pf)(std::ostream &))
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 WriteBufferedData ()
virtual ~xoutbase ()=0

Protected Member Functions

void SetXTargetCells (const XStreamMapType &cellmap) override
- Protected Member Functions inherited from xoutlibrary::xoutbase
void SetCTargetCells (const CStreamMapType &cellmap)
virtual void SetXTargetCells (const XStreamMapType &cellmap)
 xoutbase ()=default

Private Attributes

std::map< std::string, std::unique_ptr< xoutbase > > m_CellMap

Additional Inherited Members

- Protected Attributes inherited from xoutlibrary::xoutbase
CStreamMapType m_COutputs
CStreamMapType m_CTargetCells
XStreamMapType m_XOutputs
XStreamMapType m_XTargetCells

Member Typedef Documentation

◆ Self

Definition at line 45 of file xoutrow.h.

◆ Superclass

Definition at line 46 of file xoutrow.h.

Constructor & Destructor Documentation

◆ xoutrow()

xoutlibrary::xoutrow::xoutrow ( )


◆ ~xoutrow()

xoutlibrary::xoutrow::~xoutrow ( )


Member Function Documentation

◆ AddNewTargetCell()

int xoutlibrary::xoutrow::AddNewTargetCell ( const char *  name)

This method adds a new xoutcell to the map of Targets.

◆ AddOutput() [1/2]

int xoutlibrary::xoutrow::AddOutput ( const char *  name,
std::ostream *  output 

Add/Remove an output stream (like cout, or an fstream, or an xout-object). In addition to the behaviour of the Superclass's methods, these functions set the outputs of the TargetCells as well.

Reimplemented from xoutlibrary::xoutbase.

◆ AddOutput() [2/2]

int xoutlibrary::xoutrow::AddOutput ( const char *  name,
Superclass output 

Reimplemented from xoutlibrary::xoutbase.

◆ RemoveOutput()

int xoutlibrary::xoutrow::RemoveOutput ( const char *  name)

Reimplemented from xoutlibrary::xoutbase.

◆ RemoveTargetCell()

int xoutlibrary::xoutrow::RemoveTargetCell ( const char *  name)

This method removes an xoutcell to the map of Targets.

Reimplemented from xoutlibrary::xoutbase.

◆ SetOutputs() [1/2]

void xoutlibrary::xoutrow::SetOutputs ( const CStreamMapType outputmap)

Reimplemented from xoutlibrary::xoutbase.

◆ SetOutputs() [2/2]

void xoutlibrary::xoutrow::SetOutputs ( const XStreamMapType outputmap)

Reimplemented from xoutlibrary::xoutbase.

◆ SetXTargetCells()

void xoutlibrary::xoutrow::SetXTargetCells ( const XStreamMapType cellmap)

Method to set all targets at once. The outputs of these targets are not set automatically, so make sure to do it yourself.

Reimplemented from xoutlibrary::xoutbase.

◆ WriteBufferedData()

void xoutlibrary::xoutrow::WriteBufferedData ( )

Write the buffered cell data in a row to the outputs, separated by tabs.

Reimplemented from xoutlibrary::xoutbase.

◆ WriteHeaders()

virtual void xoutlibrary::xoutrow::WriteHeaders ( )

Writes the names of the target cells to the outputs.

Field Documentation

◆ m_CellMap

std::map<std::string, std::unique_ptr<xoutbase> > xoutlibrary::xoutrow::m_CellMap

Definition at line 100 of file xoutrow.h.

Generated on 2023-01-13 for elastix by doxygen 1.9.6 elastix logo