Dibbler - a portable DHCPv6  1.0.2RC1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
logger Namespace Reference

Enumerations

enum  Elogmode {
  LOGMODE_FULL, LOGMODE_SHORT, LOGMODE_PRECISE, LOGMODE_SYSLOG,
  LOGMODE_EVENTLOG
}

Functions

static void changeLogMode (Elogmode newMode)
void EchoOff ()
void EchoOn ()
std::ostream & endl (std::ostream &strum)
ostream & endl (ostream &strum)
int getLogLevel ()
string getLogName ()
void Initialize (const char *file)
ostream & logAlert ()
ostream & logCommon (int x)
ostream & logCont ()
ostream & logCrit ()
ostream & logDebug ()
ostream & logEmerg ()
ostream & logError ()
ostream & logInfo ()
ostream & logNotice ()
ostream & logWarning ()
static void openLog ()
void setColors (bool colorLogs)
void setLogLevel (int x)
void setLogMode (const std::string x)
void setLogMode (string x)
void setLogName (const std::string x)
void setLogName (string x)
void Terminate ()

Variables

ostringstream buffer
bool color = false
int curLogEntry = 8
bool echo = true
ofstream logFile
bool logFileMode = false
string logFileName
int logLevel = 8
Elogmode logmode = LOGMODE_FULL
string logname = "Init"

Enumeration Type Documentation

Enumerator:
LOGMODE_FULL 
LOGMODE_SHORT 
LOGMODE_PRECISE 
LOGMODE_SYSLOG 
LOGMODE_EVENTLOG 

Function Documentation

static void logger::changeLogMode ( Elogmode  newMode)
static

Change logging mode, possibly backend too. Some modes log into common backend, some modes have unique backends.

Parameters
newModeNew logging mode
void logger::EchoOff ( )
void logger::EchoOn ( )
std::ostream& logger::endl ( std::ostream &  strum)
ostream& logger::endl ( ostream &  strum)
int logger::getLogLevel ( )
std::string logger::getLogName ( )
void logger::Initialize ( const char *  file)

Initialize logging.

Parameters
fileFile suitable for logging into
std::ostream & logger::logAlert ( )
ostream& logger::logCommon ( int  x)
std::ostream & logger::logCont ( )
std::ostream & logger::logCrit ( )
std::ostream & logger::logDebug ( )
std::ostream & logger::logEmerg ( )
std::ostream & logger::logError ( )
std::ostream & logger::logInfo ( )
std::ostream & logger::logNotice ( )
std::ostream & logger::logWarning ( )
static void logger::openLog ( )
static

Prepare logging backend specified in logger::logmode for logging.

void logger::setColors ( bool  colorLogs)
void logger::setLogLevel ( int  x)
void logger::setLogMode ( const std::string  x)
void logger::setLogMode ( string  x)
void logger::setLogName ( const std::string  x)
void logger::setLogName ( string  x)
void logger::Terminate ( )

Close loging backend.

Variable Documentation

ostringstream logger::buffer
bool logger::color = false
int logger::curLogEntry = 8
bool logger::echo = true
ofstream logger::logFile
bool logger::logFileMode = false
string logger::logFileName
int logger::logLevel = 8
Elogmode logger::logmode = LOGMODE_FULL
string logger::logname = "Init"