Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Private Member Functions | Private Attributes | Friends
sawyer::Logger Class Reference

#include <Logger.h>

List of all members.

Public Types

enum  logLevels {
  ERROR_LEV, EXCEPTION, WARNING, INFO,
  DETAIL
}

Public Member Functions

std::ostream & entry (enum logLevels level, const char *file=0, int line=-1)
void hookFatalSignals ()
void setEnabled (bool enabled)
void setLevel (enum logLevels newLevel)
void setStream (std::ostream *stream)

Static Public Member Functions

static Loggerinstance ()

Static Public Attributes

static const char * levelNames [] = {"ERROR", "EXCEPTION", "WARNING", "INFO", "DETAIL"}

Private Member Functions

void close ()
 Logger ()
 ~Logger ()

Private Attributes

bool enabled
int level
std::ofstream * nullStream
std::ostream * stream

Friends

void loggerTermHandler (int signal)

Detailed Description

Definition at line 46 of file Logger.h.


Member Enumeration Documentation

Enumerator:
ERROR_LEV 
EXCEPTION 
WARNING 
INFO 
DETAIL 

Definition at line 57 of file Logger.h.


Constructor & Destructor Documentation

sawyer::Logger::Logger ( ) [private]

Definition at line 83 of file Logger.cpp.

sawyer::Logger::~Logger ( ) [private]

Definition at line 91 of file Logger.cpp.


Member Function Documentation

void sawyer::Logger::close ( ) [private]

Definition at line 96 of file Logger.cpp.

std::ostream & sawyer::Logger::entry ( enum logLevels  level,
const char *  file = 0,
int  line = -1 
)

Definition at line 106 of file Logger.cpp.

Definition at line 144 of file Logger.cpp.

Definition at line 77 of file Logger.cpp.

void sawyer::Logger::setEnabled ( bool  enabled)

Definition at line 128 of file Logger.cpp.

void sawyer::Logger::setLevel ( enum logLevels  newLevel)

Definition at line 133 of file Logger.cpp.

void sawyer::Logger::setStream ( std::ostream *  stream)

Definition at line 138 of file Logger.cpp.


Friends And Related Function Documentation

void loggerTermHandler ( int  signal) [friend]

Member Data Documentation

bool sawyer::Logger::enabled [private]

Definition at line 49 of file Logger.h.

int sawyer::Logger::level [private]

Definition at line 50 of file Logger.h.

const char * sawyer::Logger::levelNames = {"ERROR", "EXCEPTION", "WARNING", "INFO", "DETAIL"} [static]

Definition at line 65 of file Logger.h.

std::ofstream* sawyer::Logger::nullStream [private]

Definition at line 54 of file Logger.h.

std::ostream* sawyer::Logger::stream [private]

Definition at line 52 of file Logger.h.


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


roch_base
Author(s): Mike Purvis , Paul Bovbel , Carl
autogenerated on Sat Jun 8 2019 20:32:33