Flow123d  release_3.0.0-1113-g35b167a
Public Member Functions | Static Public Attributes | Private Attributes | List of all members
StreamMask Class Reference

Helper class, store mask specifying streams. More...

#include <logger.hh>

Collaboration diagram for StreamMask:
Collaboration graph
[legend]

Public Member Functions

 StreamMask ()
 Empty constructor. More...
 
 StreamMask (int mask)
 Constructor set mask_ value. More...
 
StreamMask operator& (const StreamMask &other)
 
StreamMask operator| (const StreamMask &other)
 
int operator() (void)
 

Static Public Attributes

static StreamMask cout = StreamMask(0b00000001)
 Predefined mask of std::cout output. More...
 
static StreamMask cerr = StreamMask(0b00000010)
 Predefined mask of std::cerr output. More...
 
static StreamMask log = StreamMask(0b00000100)
 Predefined mask of log file output. More...
 

Private Attributes

int mask_
 

Detailed Description

Helper class, store mask specifying streams.

Defines masks of all used streams as static methods and allows combining and comparing masks using the overloaded operators.

Definition at line 41 of file logger.hh.

Constructor & Destructor Documentation

StreamMask::StreamMask ( )
inline

Empty constructor.

Definition at line 44 of file logger.hh.

Here is the caller graph for this function:

StreamMask::StreamMask ( int  mask)
inline

Constructor set mask_ value.

Definition at line 48 of file logger.hh.

Member Function Documentation

StreamMask StreamMask::operator& ( const StreamMask other)

Definition at line 44 of file logger.cc.

int StreamMask::operator() ( void  )

Definition at line 54 of file logger.cc.

StreamMask StreamMask::operator| ( const StreamMask other)

Definition at line 49 of file logger.cc.

Member Data Documentation

StreamMask StreamMask::cerr = StreamMask(0b00000010)
static

Predefined mask of std::cerr output.

Definition at line 55 of file logger.hh.

StreamMask StreamMask::cout = StreamMask(0b00000001)
static

Predefined mask of std::cout output.

Definition at line 52 of file logger.hh.

StreamMask StreamMask::log = StreamMask(0b00000100)
static

Predefined mask of log file output.

Definition at line 58 of file logger.hh.

int StreamMask::mask_
private

Definition at line 70 of file logger.hh.


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