tlx
SpacingLogger Class Reference

A logging class which outputs spaces between elements pushed via operator<<. More...

#include <core.hpp>

Public Member Functions

 SpacingLogger ()
 construction: add prefix if desired More...
 
template<typename AnyType >
SpacingLoggeroperator<< (const AnyType &at)
 output any type, including io manipulators More...
 
 ~SpacingLogger ()
 destructor: output a newline More...
 

Private Attributes

bool first_
 true until the first element it outputted. More...
 
std::ostringstream oss_
 collector stream More...
 

Detailed Description

A logging class which outputs spaces between elements pushed via operator<<.

Depending on the real parameter the output may be suppressed.

Definition at line 113 of file core.hpp.

Constructor & Destructor Documentation

◆ SpacingLogger()

construction: add prefix if desired

Definition at line 107 of file core.cpp.

◆ ~SpacingLogger()

destructor: output a newline

Definition at line 113 of file core.cpp.

Member Function Documentation

◆ operator<<()

SpacingLogger& operator<< ( const AnyType &  at)
inline

output any type, including io manipulators

Definition at line 128 of file core.hpp.

Member Data Documentation

◆ first_

bool first_
private

true until the first element it outputted.

Definition at line 117 of file core.hpp.

◆ oss_

std::ostringstream oss_
private

collector stream

Definition at line 120 of file core.hpp.


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