BitShares-Core  7.0.2
BitShares blockchain node software and command-line wallet software
Classes | Public Member Functions | Static Public Member Functions | Friends | List of all members
fc::logger Class Reference

#include <logger.hpp>

Classes

class  impl
 

Public Member Functions

 logger ()
 
 logger (const string &name, const logger &parent=nullptr)
 
 logger (std::nullptr_t)
 
 logger (const logger &c)
 
 logger (logger &&c)
 
 ~logger ()
 
loggeroperator= (const logger &)
 
loggeroperator= (logger &&)
 
loggerset_log_level (log_level e)
 
log_level get_log_level () const
 
loggerset_parent (const logger &l)
 
logger get_parent () const
 
void set_name (const std::string &n)
 
const std::string & name () const
 
void add_appender (const appender::ptr &a)
 
std::vector< appender::ptrget_appenders () const
 
void remove_appender (const appender::ptr &a)
 
bool is_enabled (log_level e) const
 
void log (log_message m)
 

Static Public Member Functions

static logger get (const std::string &name="default")
 

Friends

bool operator== (const logger &, std::nullptr_t)
 
bool operator!= (const logger &, std::nullptr_t)
 

Detailed Description

void my_class::func()
{
fc_dlog( my_class_logger, "Format four: ${arg} five: ${five}", ("arg",4)("five",5) );
}

Definition at line 21 of file logger.hpp.

Constructor & Destructor Documentation

◆ logger() [1/5]

fc::logger::logger ( )

Definition at line 28 of file logger.cpp.

◆ logger() [2/5]

fc::logger::logger ( const string &  name,
const logger parent = nullptr 
)

Definition at line 33 of file logger.cpp.

◆ logger() [3/5]

fc::logger::logger ( std::nullptr_t  )

Definition at line 31 of file logger.cpp.

◆ logger() [4/5]

fc::logger::logger ( const logger c)

Definition at line 41 of file logger.cpp.

◆ logger() [5/5]

fc::logger::logger ( logger &&  c)

Definition at line 44 of file logger.cpp.

◆ ~logger()

fc::logger::~logger ( )

Definition at line 47 of file logger.cpp.

Member Function Documentation

◆ add_appender()

void fc::logger::add_appender ( const appender::ptr a)

Definition at line 99 of file logger.cpp.

◆ get()

logger fc::logger::get ( const std::string &  name = "default")
static

Definition at line 87 of file logger.cpp.

◆ get_appenders()

std::vector< appender::ptr > fc::logger::get_appenders ( ) const

Definition at line 109 of file logger.cpp.

◆ get_log_level()

log_level fc::logger::get_log_level ( ) const

Definition at line 96 of file logger.cpp.

◆ get_parent()

logger fc::logger::get_parent ( ) const

Definition at line 93 of file logger.cpp.

◆ is_enabled()

bool fc::logger::is_enabled ( log_level  e) const

Definition at line 60 of file logger.cpp.

◆ log()

void fc::logger::log ( log_message  m)

Definition at line 64 of file logger.cpp.

◆ name()

const std::string & fc::logger::name ( ) const

Definition at line 75 of file logger.cpp.

◆ operator=() [1/2]

logger & fc::logger::operator= ( const logger l)

Definition at line 49 of file logger.cpp.

◆ operator=() [2/2]

logger & fc::logger::operator= ( logger &&  l)

Definition at line 53 of file logger.cpp.

◆ remove_appender()

void fc::logger::remove_appender ( const appender::ptr a)

Definition at line 102 of file logger.cpp.

◆ set_log_level()

logger & fc::logger::set_log_level ( log_level  e)

Definition at line 97 of file logger.cpp.

◆ set_name()

void fc::logger::set_name ( const std::string &  n)

Definition at line 74 of file logger.cpp.

◆ set_parent()

logger & fc::logger::set_parent ( const logger l)

Definition at line 94 of file logger.cpp.

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( const logger l,
std::nullptr_t   
)
friend

Definition at line 58 of file logger.cpp.

◆ operator==

bool operator== ( const logger l,
std::nullptr_t   
)
friend

Definition at line 57 of file logger.cpp.


The documentation for this class was generated from the following files:
fc_dlog
#define fc_dlog(LOGGER, FORMAT,...)
Definition: logger.hpp:76