PPL6-Icon Patrick's Programming Library Version 6.4.21 - Dokumentation
ppl6::CLog Klassenreferenz

Allgemeine Logging-Klasse.

Öffentliche Typen

enum  SYSLOG_FACILITY {
  SYSLOG_AUTH =1, SYSLOG_AUTHPRIV, SYSLOG_CONSOLE, SYSLOG_CRON,
  SYSLOG_DAEMON, SYSLOG_FTP, SYSLOG_KERN, SYSLOG_LPR,
  SYSLOG_MAIL, SYSLOG_NEWS, SYSLOG_NTP, SYSLOG_SECURITY,
  SYSLOG_SYSLOG, SYSLOG_USER, SYSLOG_UUCP, SYSLOG_LOCAL0,
  SYSLOG_LOCAL1, SYSLOG_LOCAL2, SYSLOG_LOCAL3, SYSLOG_LOCAL4,
  SYSLOG_LOCAL5, SYSLOG_LOCAL6, SYSLOG_LOCAL7
}
 

Öffentliche Methoden

 CLog ()
 
virtual ~CLog ()
 
int AddLogHandler (CLogHandler *handler)
 
void closeSyslog ()
 
void DeleteFilter (const char *module, const char *function)
 
void DeleteFilter (const char *file, int line)
 
int DeleteLogHandler (CLogHandler *handler)
 
int GetLogLevel (int facility)
 
void HexDump (int facility, int level, const void *address, int bytes)
 
void HexDump (const void *address, int bytes)
 
void LogError (int level)
 
void LogError ()
 
void LogError (const char *file, int line)
 
void LogError (const char *module, const char *function, const char *file, int line)
 
void LogError (int facility, int level, const char *file, int line)
 
void LogError (int facility, int level, const char *module, const char *function, const char *file, int line)
 
void LogErrorCode (int level, ppluint32 errorcode)
 
void LogErrorCode (ppluint32 errorcode)
 
void openSyslog (const CString &ident, SYSLOG_FACILITY facility=SYSLOG_USER)
 
void Print (int facility, int level, const char *text)
 
void Print (int facility, int level, const char *file, int line, const char *text)
 
void Print (int facility, int level, const char *module, const char *function, const char *file, int line, const char *text)
 
void Print (int level, const char *text)
 
void PrintArray (int facility, int level, const CAssocArray *a, const char *fmt,...)
 
void PrintArray (int facility, int level, const char *module, const char *function, const char *file, int line, const CAssocArray *a, const char *fmt,...)
 
void PrintArraySingleLine (int facility, int level, const char *module, const char *function, const char *file, int line, const CAssocArray *a, const char *fmt,...)
 
void Printf (int facility, int level, const char *file, int line, const char *fmt,...)
 
void Printf (int facility, int level, const char *module, const char *function, const char *file, int line, const char *fmt,...)
 
void Printfs (int level, const char *fmt,...)
 
void Printfs (int facility, int level, const char *fmt,...)
 
void SetConsole (bool flag=true, int facility=LOG::DEBUG, int level=1)
 
int SetFilter (const char *module, const char *function, int level)
 
int SetFilter (const char *file, int line, int level)
 
int SetLogfile (int facility, const char *filename)
 
void SetLogLevel (int facility, int level=1)
 
int SetLogRotate (ppluint64 maxsize, int generations)
 
void Terminate ()
 

Private Methoden

void CheckRotate (int facility)
 
int IsFiltered (const char *module, const char *function, const char *file, int line, int level)
 
void Output (int facility, int level, const char *module, const char *function, const char *file, int line, const char *buffer, bool printdate=true)
 
void OutputArray (int facility, int level, const char *module, const char *function, const char *file, int line, const CAssocArray *a, const char *prefix, CString *Out=NULL)
 
bool shouldPrint (const char *module, const char *function, const char *file, int line, int facility, int level)
 

Private Attribute

bool console_enabled
 
int console_facility
 
int console_level
 
int debuglevel [NUMFACILITIES]
 
CAssocArrayFilterFile
 
CAssocArrayFilterModule
 
void * firsthandler
 
int generations
 
bool inrotate
 
void * lasthandler
 
bool logconsole
 
CFile logff [NUMFACILITIES]
 
CString logfilename [NUMFACILITIES]
 
bool logThreadId
 
ppluint64 maxsize
 
CMutex mutex
 
int rotate_mechanism
 
SYSLOG_FACILITY syslogFacility
 
CString syslogIdent
 
bool useSyslog
 

Dokumentation der Aufzählungstypen

Aufzählungswerte
SYSLOG_AUTH 
SYSLOG_AUTHPRIV 
SYSLOG_CONSOLE 
SYSLOG_CRON 
SYSLOG_DAEMON 
SYSLOG_FTP 
SYSLOG_KERN 
SYSLOG_LPR 
SYSLOG_MAIL 
SYSLOG_NEWS 
SYSLOG_NTP 
SYSLOG_SECURITY 
SYSLOG_SYSLOG 
SYSLOG_USER 
SYSLOG_UUCP 
SYSLOG_LOCAL0 
SYSLOG_LOCAL1 
SYSLOG_LOCAL2 
SYSLOG_LOCAL3 
SYSLOG_LOCAL4 
SYSLOG_LOCAL5 
SYSLOG_LOCAL6 
SYSLOG_LOCAL7 

Beschreibung der Konstruktoren und Destruktoren

ppl6::CLog::CLog ( )
ppl6::CLog::~CLog ( )
virtual

Dokumentation der Elementfunktionen

int ppl6::CLog::AddLogHandler ( CLogHandler handler)
void ppl6::CLog::CheckRotate ( int  facility)
private
void ppl6::CLog::closeSyslog ( )
void ppl6::CLog::DeleteFilter ( const char *  module,
const char *  function 
)
void ppl6::CLog::DeleteFilter ( const char *  file,
int  line 
)
int ppl6::CLog::DeleteLogHandler ( CLogHandler handler)
int ppl6::CLog::GetLogLevel ( int  facility)
void ppl6::CLog::HexDump ( int  facility,
int  level,
const void *  address,
int  bytes 
)
void ppl6::CLog::HexDump ( const void *  address,
int  bytes 
)
int ppl6::CLog::IsFiltered ( const char *  module,
const char *  function,
const char *  file,
int  line,
int  level 
)
private
void ppl6::CLog::LogError ( int  level)
void ppl6::CLog::LogError ( )
void ppl6::CLog::LogError ( const char *  file,
int  line 
)
void ppl6::CLog::LogError ( const char *  module,
const char *  function,
const char *  file,
int  line 
)
void ppl6::CLog::LogError ( int  facility,
int  level,
const char *  file,
int  line 
)
void ppl6::CLog::LogError ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line 
)
void ppl6::CLog::LogErrorCode ( int  level,
ppluint32  errorcode 
)
void ppl6::CLog::LogErrorCode ( ppluint32  errorcode)
void ppl6::CLog::openSyslog ( const CString ident,
SYSLOG_FACILITY  facility = SYSLOG_USER 
)
void ppl6::CLog::Output ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line,
const char *  buffer,
bool  printdate = true 
)
private
void ppl6::CLog::OutputArray ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line,
const CAssocArray a,
const char *  prefix,
CString Out = NULL 
)
private
void ppl6::CLog::Print ( int  facility,
int  level,
const char *  text 
)
void ppl6::CLog::Print ( int  facility,
int  level,
const char *  file,
int  line,
const char *  text 
)
void ppl6::CLog::Print ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line,
const char *  text 
)
void ppl6::CLog::Print ( int  level,
const char *  text 
)
void ppl6::CLog::PrintArray ( int  facility,
int  level,
const CAssocArray a,
const char *  fmt,
  ... 
)
void ppl6::CLog::PrintArray ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line,
const CAssocArray a,
const char *  fmt,
  ... 
)
void ppl6::CLog::PrintArraySingleLine ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line,
const CAssocArray a,
const char *  fmt,
  ... 
)
void ppl6::CLog::Printf ( int  facility,
int  level,
const char *  file,
int  line,
const char *  fmt,
  ... 
)
void ppl6::CLog::Printf ( int  facility,
int  level,
const char *  module,
const char *  function,
const char *  file,
int  line,
const char *  fmt,
  ... 
)
void ppl6::CLog::Printfs ( int  level,
const char *  fmt,
  ... 
)
void ppl6::CLog::Printfs ( int  facility,
int  level,
const char *  fmt,
  ... 
)
void ppl6::CLog::SetConsole ( bool  flag = true,
int  facility = LOG::DEBUG,
int  level = 1 
)
int ppl6::CLog::SetFilter ( const char *  module,
const char *  function,
int  level 
)
int ppl6::CLog::SetFilter ( const char *  file,
int  line,
int  level 
)
int ppl6::CLog::SetLogfile ( int  facility,
const char *  filename 
)
void ppl6::CLog::SetLogLevel ( int  facility,
int  level = 1 
)
int ppl6::CLog::SetLogRotate ( ppluint64  maxsize,
int  generations 
)
bool ppl6::CLog::shouldPrint ( const char *  module,
const char *  function,
const char *  file,
int  line,
int  facility,
int  level 
)
private
void ppl6::CLog::Terminate ( )

Dokumentation der Datenelemente

bool ppl6::CLog::console_enabled
private
int ppl6::CLog::console_facility
private
int ppl6::CLog::console_level
private
int ppl6::CLog::debuglevel[NUMFACILITIES]
private
CAssocArray * ppl6::CLog::FilterFile
private
CAssocArray* ppl6::CLog::FilterModule
private
void* ppl6::CLog::firsthandler
private
int ppl6::CLog::generations
private
bool ppl6::CLog::inrotate
private
void * ppl6::CLog::lasthandler
private
bool ppl6::CLog::logconsole
private
CFile ppl6::CLog::logff[NUMFACILITIES]
private
CString ppl6::CLog::logfilename[NUMFACILITIES]
private
bool ppl6::CLog::logThreadId
private
ppluint64 ppl6::CLog::maxsize
private
CMutex ppl6::CLog::mutex
private
int ppl6::CLog::rotate_mechanism
private
SYSLOG_FACILITY ppl6::CLog::syslogFacility
private
CString ppl6::CLog::syslogIdent
private
bool ppl6::CLog::useSyslog
private

Die Dokumentation für diese Klasse wurde erzeugt aufgrund der Dateien: