PLearn 0.1
Classes | Namespaces | Defines | Enumerations | Functions
pl_log.h File Reference
#include <vector>
#include <deque>
#include <map>
#include <set>
#include <string>
#include "PStream.h"
Include dependency graph for pl_log.h:

Go to the source code of this file.

Classes

class  PLearn::PL_LogPlugin
 Provides several back-ends for displaying the log messages. More...
class  PLearn::PL_LogPluginPStream
 Default implementation of PL_LogPlugin :: outputs to specified PStream (perr by default) More...
class  PLearn::PL_LogPluginServer
 Server implementation of PL_LogPlugin :: outputs to client through opened socket. More...
class  PLearn::PL_LogPluginInterceptor
 Forward declare. More...
class  PLearn::PL_Log
struct  PLearn::PL_Log::Heading
 Support stuff for heading manipulator. More...

Namespaces

namespace  PLearn
 

< for swap


Defines

#define PL_LOG_MAXVERBOSITY   1000
#define PL_LOG_MINVERBOSITY   1
#define PL_LOG_VERBOSITY   499
#define PL_LOG(v)   if (v <= PL_LOG_VERBOSITY) PL_Log::instance().logger(v)
#define MAND_LOG   PL_LOG(VLEVEL_MAND)
#define IMP_LOG   PL_LOG(VLEVEL_IMP)
#define NORMAL_LOG   PL_LOG(VLEVEL_NORMAL)
#define DBG_LOG   PL_LOG(VLEVEL_DBG)
#define EXTREME_LOG   PL_LOG(VLEVEL_EXTREME)
#define PL_LEVEL_NAMED_LOG(name, level)
 An explicitly named log with a given level. For use within templates.
#define MAND_NAMED_LOG(name)   PL_LEVEL_NAMED_LOG(name, VLEVEL_MAND)
 Define various leveled named logs.
#define IMP_NAMED_LOG(name)   PL_LEVEL_NAMED_LOG(name, VLEVEL_IMP)
#define NAMED_LOG(name)   PL_LEVEL_NAMED_LOG(name, VLEVEL_NORMAL)
#define DBG_NAMED_LOG(name)   PL_LEVEL_NAMED_LOG(name, VLEVEL_DBG)
#define EXTREME_NAMED_LOG(name)   PL_LEVEL_NAMED_LOG(name, VLEVEL_EXTREME)

Enumerations

enum  PLearn::VerbosityLevel {
  PLearn::VLEVEL_MAND = 0, PLearn::VLEVEL_IMP = 1, PLearn::VLEVEL_NORMAL = 5, PLearn::VLEVEL_DBG = 10,
  PLearn::VLEVEL_EXTREME = 500
}

Functions

PStream & PLearn::plsep (PStream &)
 If the "PL_LOG_MODULE_NAME" variable is defined before pl_log.h is included, then *_MODULE_LOG are defined to provide module-specified logging for that module.
PL_Log::Heading PLearn::plhead (string s)
 Manipulator that displays a nice heading.
PStream & PLearn::operator<< (PStream &, PL_Log::Heading)
 Actually draw the heading.

Detailed Description

Definition in file pl_log.h.


Define Documentation

#define DBG_LOG   PL_LOG(VLEVEL_DBG)
#define DBG_NAMED_LOG (   name)    PL_LEVEL_NAMED_LOG(name, VLEVEL_DBG)

Definition at line 309 of file pl_log.h.

#define EXTREME_LOG   PL_LOG(VLEVEL_EXTREME)

Definition at line 297 of file pl_log.h.

Referenced by PLearn::PPath::canonical().

#define EXTREME_NAMED_LOG (   name)    PL_LEVEL_NAMED_LOG(name, VLEVEL_EXTREME)

Definition at line 310 of file pl_log.h.

Referenced by PLearn::ChemicalICP::run().

#define IMP_LOG   PL_LOG(VLEVEL_IMP)

Definition at line 294 of file pl_log.h.

Referenced by PLearn::PLearnServer::run().

#define IMP_NAMED_LOG (   name)    PL_LEVEL_NAMED_LOG(name, VLEVEL_IMP)

Definition at line 307 of file pl_log.h.

#define MAND_LOG   PL_LOG(VLEVEL_MAND)
#define MAND_NAMED_LOG (   name)    PL_LEVEL_NAMED_LOG(name, VLEVEL_MAND)

Define various leveled named logs.

Definition at line 306 of file pl_log.h.

#define NAMED_LOG (   name)    PL_LEVEL_NAMED_LOG(name, VLEVEL_NORMAL)

Definition at line 308 of file pl_log.h.

Referenced by PLearn::VMatrixExtensionRegistrar::registerExtension().

#define NORMAL_LOG   PL_LOG(VLEVEL_NORMAL)
#define PL_LEVEL_NAMED_LOG (   name,
  level 
)
Value:
if (level <= PL_LOG_VERBOSITY)                      \
        PL_Log::instance().namedLogger(name, level)

An explicitly named log with a given level. For use within templates.

Definition at line 301 of file pl_log.h.

#define PL_LOG (   v)    if (v <= PL_LOG_VERBOSITY) PL_Log::instance().logger(v)

Definition at line 292 of file pl_log.h.

Referenced by PLearn::PLearnService::log_callback(), and PLearn::PLLogTest::perform().

#define PL_LOG_MAXVERBOSITY   1000

Definition at line 62 of file pl_log.h.

#define PL_LOG_MINVERBOSITY   1

Definition at line 66 of file pl_log.h.

#define PL_LOG_VERBOSITY   499

Definition at line 70 of file pl_log.h.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines