LIEF: Library to Instrument Executable Formats Version 2.0.0
Loading...
Searching...
No Matches
LIEF::logging Namespace Reference

Namespaces

namespace  named

Classes

class  Scoped

Enumerations

enum class  Level : uint32_t {
  Off = 0 , Trace , Debug , Info ,
  Warn , Err , Critical
}
 Hierarchical logging level More...

Functions

Level get_level ()
 Current log level.
const char * to_string (Level e)
void disable ()
 Globally disable the logging module.
void enable ()
 Globally enable the logging module.
void set_level (Level level)
 Change the logging level (hierarchical).
void set_path (const std::string &path)
 Change the logger to a file-based logging and set its path.
void log (Level level, const std::string &msg)
 Log a message with the LIEF's logger.
void log (Level level, const std::string &fmt, const std::vector< std::string > &args)
template<typename... Args>
void log (Level level, const std::string &fmt, const Args &... args)
void set_logger (std::shared_ptr< spdlog::logger > logger)
void reset ()
void enable_debug ()
void debug (const std::string &msg)
void debug (const std::string &fmt, const std::vector< std::string > &args)
template<typename... Args>
void debug (const std::string &fmt, const Args &... args)
void info (const std::string &msg)
void info (const std::string &fmt, const std::vector< std::string > &args)
template<typename... Args>
void info (const std::string &fmt, const Args &... args)
void warn (const std::string &msg)
void warn (const std::string &fmt, const std::vector< std::string > &args)
template<typename... Args>
void warn (const std::string &fmt, const Args &... args)
void err (const std::string &msg)
void err (const std::string &fmt, const std::vector< std::string > &args)
template<typename... Args>
void err (const std::string &fmt, const Args &... args)
void critical (const std::string &msg)
void critical (const std::string &fmt, const std::vector< std::string > &args)
template<typename... Args>
void critical (const std::string &fmt, const Args &... args)

Enumeration Type Documentation

◆ Level

enum class LIEF::logging::Level : uint32_t
strong

Hierarchical logging level

From a given level set, all levels below this level are enabled

For example, if Level::Info is enabled then Level::Warn, Level::Err are also enabled

Enumerator
Off 
Trace 
Debug 
Info 
Warn 
Err 
Critical 

Function Documentation

◆ critical() [1/3]

template<typename... Args>
void LIEF::logging::critical ( const std::string & fmt,
const Args &... args )

References critical().

◆ critical() [2/3]

void LIEF::logging::critical ( const std::string & fmt,
const std::vector< std::string > & args )
inline

References Critical, and log().

◆ critical() [3/3]

void LIEF::logging::critical ( const std::string & msg)
inline

References Critical, and log().

Referenced by critical().

◆ debug() [1/3]

template<typename... Args>
void LIEF::logging::debug ( const std::string & fmt,
const Args &... args )

References debug().

◆ debug() [2/3]

void LIEF::logging::debug ( const std::string & fmt,
const std::vector< std::string > & args )
inline

References Debug, and log().

◆ debug() [3/3]

void LIEF::logging::debug ( const std::string & msg)
inline

References Debug, and log().

Referenced by debug().

◆ disable()

void LIEF::logging::disable ( )

Globally disable the logging module.

References LIEF_API.

◆ enable()

void LIEF::logging::enable ( )

Globally enable the logging module.

References LIEF_API.

◆ enable_debug()

void LIEF::logging::enable_debug ( )
inline

References Debug, and set_level().

◆ err() [1/3]

template<typename... Args>
void LIEF::logging::err ( const std::string & fmt,
const Args &... args )

References err().

◆ err() [2/3]

void LIEF::logging::err ( const std::string & fmt,
const std::vector< std::string > & args )
inline

References Err, and log().

◆ err() [3/3]

void LIEF::logging::err ( const std::string & msg)
inline

References Err, and log().

Referenced by LIEF::runtime::Memory::Chunk::change_permissions(), and err().

◆ get_level()

Level LIEF::logging::get_level ( )

Current log level.

References LIEF_API.

Referenced by LIEF::logging::Scoped::Scoped(), and LIEF::logging::Scoped::Scoped().

◆ info() [1/3]

template<typename... Args>
void LIEF::logging::info ( const std::string & fmt,
const Args &... args )

References info().

◆ info() [2/3]

void LIEF::logging::info ( const std::string & fmt,
const std::vector< std::string > & args )
inline

References Info, and log().

◆ info() [3/3]

void LIEF::logging::info ( const std::string & msg)
inline

References Info, and log().

Referenced by info().

◆ log() [1/3]

template<typename... Args>
void LIEF::logging::log ( Level level,
const std::string & fmt,
const Args &... args )

References log().

◆ log() [2/3]

void LIEF::logging::log ( Level level,
const std::string & fmt,
const std::vector< std::string > & args )

References LIEF_API.

◆ log() [3/3]

void LIEF::logging::log ( Level level,
const std::string & msg )

Log a message with the LIEF's logger.

References LIEF_API.

Referenced by critical(), critical(), debug(), debug(), err(), err(), info(), info(), log(), warn(), and warn().

◆ reset()

void LIEF::logging::reset ( )

References LIEF_API.

◆ set_level()

void LIEF::logging::set_level ( Level level)

Change the logging level (hierarchical).

References LIEF_API.

Referenced by enable_debug(), and LIEF::logging::Scoped::set_level().

◆ set_logger()

void LIEF::logging::set_logger ( std::shared_ptr< spdlog::logger > logger)

References LIEF_API.

◆ set_path()

void LIEF::logging::set_path ( const std::string & path)

Change the logger to a file-based logging and set its path.

References LIEF_API.

◆ to_string()

const char * LIEF::logging::to_string ( Level e)

References LIEF_API.

◆ warn() [1/3]

template<typename... Args>
void LIEF::logging::warn ( const std::string & fmt,
const Args &... args )

References warn().

◆ warn() [2/3]

void LIEF::logging::warn ( const std::string & fmt,
const std::vector< std::string > & args )
inline

References log(), and Warn.

◆ warn() [3/3]

void LIEF::logging::warn ( const std::string & msg)
inline

References log(), and Warn.

Referenced by warn().