cpp_redis  4.0.0
cpp_redis is a C++11 Asynchronous Multi-Platform Lightweight Redis Client, with support for synchronous operations and pipelining.
Public Types | Public Member Functions | List of all members
cpp_redis::logger Class Reference

#include <logger.hpp>

Inheritance diagram for cpp_redis::logger:
cpp_redis::logger_iface

Public Types

enum  log_level { error = 0, warn = 1, info = 2, debug = 3 }
 

Public Member Functions

 logger (log_level level=log_level::info)
 ctor
 
 ~logger (void)=default
 dtor
 
 logger (const logger &)=default
 copy ctor
 
loggeroperator= (const logger &)=default
 assignment operator
 
void debug (const std::string &msg, const std::string &file, std::size_t line)
 
void info (const std::string &msg, const std::string &file, std::size_t line)
 
void warn (const std::string &msg, const std::string &file, std::size_t line)
 
void error (const std::string &msg, const std::string &file, std::size_t line)
 
- Public Member Functions inherited from cpp_redis::logger_iface
 logger_iface (void)=default
 ctor
 
virtual ~logger_iface (void)=default
 dtor
 
 logger_iface (const logger_iface &)=default
 copy ctor
 
logger_ifaceoperator= (const logger_iface &)=default
 assignment operator
 

Detailed Description

default logger class provided by the library

Member Enumeration Documentation

◆ log_level

log level

Member Function Documentation

◆ debug()

void cpp_redis::logger::debug ( const std::string &  msg,
const std::string &  file,
std::size_t  line 
)
virtual

debug logging

Parameters
msgmessage to be logged
filefile from which the message is coming
lineline in the file of the message

Implements cpp_redis::logger_iface.

◆ error()

void cpp_redis::logger::error ( const std::string &  msg,
const std::string &  file,
std::size_t  line 
)
virtual

error logging

Parameters
msgmessage to be logged
filefile from which the message is coming
lineline in the file of the message

Implements cpp_redis::logger_iface.

◆ info()

void cpp_redis::logger::info ( const std::string &  msg,
const std::string &  file,
std::size_t  line 
)
virtual

info logging

Parameters
msgmessage to be logged
filefile from which the message is coming
lineline in the file of the message

Implements cpp_redis::logger_iface.

◆ warn()

void cpp_redis::logger::warn ( const std::string &  msg,
const std::string &  file,
std::size_t  line 
)
virtual

warn logging

Parameters
msgmessage to be logged
filefile from which the message is coming
lineline in the file of the message

Implements cpp_redis::logger_iface.


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