Tapkee
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
LoggingSingleton Class Reference

#include <logging.hpp>

Public Member Functions

LoggerImplementationget_logger_impl () const
 
void set_logger_impl (LoggerImplementation *i)
 
void enable_info ()
 
void disable_info ()
 
bool is_info_enabled ()
 
void message_info (const std::string &msg)
 
void enable_warning ()
 
void disable_warning ()
 
bool is_warning_enabled ()
 
void message_warning (const std::string &msg)
 
void enable_debug ()
 
void disable_debug ()
 
bool is_debug_enabled ()
 
void message_debug (const std::string &msg)
 
void enable_error ()
 
void disable_error ()
 
bool is_error_enabled ()
 
void message_error (const std::string &msg)
 
void enable_benchmark ()
 
void disable_benchmark ()
 
bool is_benchmark_enabled ()
 
void message_benchmark (const std::string &msg)
 

Static Public Member Functions

static LoggingSingletoninstance ()
 

Private Member Functions

 LoggingSingleton ()
 
 ~LoggingSingleton ()
 
 LoggingSingleton (const LoggingSingleton &ls)
 
void operator= (const LoggingSingleton &ls)
 

Private Attributes

LoggerImplementationimpl
 
bool info_enabled
 
bool warning_enabled
 
bool debug_enabled
 
bool error_enabled
 
bool benchmark_enabled
 

Detailed Description

Main logging singleton used by the library. Can use provided LoggerImplementation if necessary. By default uses DefaultLoggerImplementation.

Definition at line 72 of file logging.hpp.

Constructor & Destructor Documentation

LoggingSingleton ( )
private

Definition at line 75 of file logging.hpp.

~LoggingSingleton ( )
private

Definition at line 83 of file logging.hpp.

LoggingSingleton ( const LoggingSingleton ls)
private

Member Function Documentation

void disable_benchmark ( )

Definition at line 117 of file logging.hpp.

void disable_debug ( )

Definition at line 115 of file logging.hpp.

void disable_error ( )

Definition at line 116 of file logging.hpp.

void disable_info ( )

Definition at line 113 of file logging.hpp.

void disable_warning ( )

Definition at line 114 of file logging.hpp.

void enable_benchmark ( )

Definition at line 117 of file logging.hpp.

void enable_debug ( )

Definition at line 115 of file logging.hpp.

void enable_error ( )

Definition at line 116 of file logging.hpp.

void enable_info ( )

Definition at line 113 of file logging.hpp.

void enable_warning ( )

Definition at line 114 of file logging.hpp.

LoggerImplementation* get_logger_impl ( ) const

getter for logger implementation

Returns
current logger implementation

Definition at line 108 of file logging.hpp.

static LoggingSingleton& instance ( )
static
Returns
instance of the singleton

Definition at line 100 of file logging.hpp.

bool is_benchmark_enabled ( )

Definition at line 117 of file logging.hpp.

bool is_debug_enabled ( )

Definition at line 115 of file logging.hpp.

bool is_error_enabled ( )

Definition at line 116 of file logging.hpp.

bool is_info_enabled ( )

Definition at line 113 of file logging.hpp.

bool is_warning_enabled ( )

Definition at line 114 of file logging.hpp.

void message_benchmark ( const std::string &  msg)

Definition at line 117 of file logging.hpp.

void message_debug ( const std::string &  msg)

Definition at line 115 of file logging.hpp.

void message_error ( const std::string &  msg)

Definition at line 116 of file logging.hpp.

void message_info ( const std::string &  msg)

Definition at line 113 of file logging.hpp.

void message_warning ( const std::string &  msg)

Definition at line 114 of file logging.hpp.

void operator= ( const LoggingSingleton ls)
private
void set_logger_impl ( LoggerImplementation i)

setter for logger implementation

Parameters
ilogger implementation to be set

Definition at line 111 of file logging.hpp.

Member Data Documentation

bool benchmark_enabled
private

Definition at line 96 of file logging.hpp.

bool debug_enabled
private

Definition at line 94 of file logging.hpp.

bool error_enabled
private

Definition at line 95 of file logging.hpp.

LoggerImplementation* impl
private

Definition at line 90 of file logging.hpp.

bool info_enabled
private

Definition at line 92 of file logging.hpp.

bool warning_enabled
private

Definition at line 93 of file logging.hpp.


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