Monero
Loading...
Searching...
No Matches
el Namespace Reference

Easylogging++ entry namespace. More...

Namespaces

namespace  base
 Namespace containing base/internal functionality used by Easylogging++.

Classes

struct  StringToLevelItem
struct  ConfigurationStringToTypeItem
class  Callback
class  LevelHelper
 Static class that contains helper functions for el::Level. More...
class  ConfigurationTypeHelper
 Static class that contains helper functions for el::ConfigurationType. More...
class  Loggable
 Base of Easylogging++ friendly class. More...
class  CustomFormatSpecifier
 User-provided custom format specifier. More...
class  Configuration
 Represents single configuration that has representing level, configuration type and a string based value. More...
class  Configurations
 Thread-safe Configuration repository. More...
class  LogDispatchData
class  LogDispatchCallback
class  PerformanceTrackingCallback
class  LoggerRegistrationCallback
class  LogBuilder
class  Logger
 Represents a logger holding ID and configurations we need to write logs. More...
class  LogMessage
class  SysLogInitializer
 Initializes syslog with process ID, options and facility. calls closelog() on d'tor. More...
class  Helpers
 Static helpers for developers. More...
class  Loggers
 Static helpers to deal with loggers and their configurations. More...
class  VersionInfo

Typedefs

typedef std::function< void(const char *, std::size_t)> PreRollOutCallback
typedef std::function< std::string(const LogMessage *)> FormatSpecifierValueResolver
 Resolving function for format specifier.
typedef std::shared_ptr< LogBuilderLogBuilderPtr

Enumerations

enum class  Level : base::type::EnumType {
  Global = 1 , Trace = 2 , Debug = 4 , Fatal = 8 ,
  Error = 16 , Warning = 32 , Verbose = 64 , Info = 128 ,
  Unknown = 1010
}
 Represents enumeration for severity level used to determine level of logging. More...
enum class  Color : base::type::EnumType {
  Default , Red , Green , Yellow ,
  Blue , Magenta , Cyan
}
enum class  ConfigurationType : base::type::EnumType {
  Enabled = 1 , ToFile = 2 , ToStandardOutput = 4 , Format = 8 ,
  Filename = 16 , SubsecondPrecision = 32 , MillisecondsWidth = SubsecondPrecision , PerformanceTracking = 64 ,
  MaxLogFileSize = 128 , LogFlushThreshold = 256 , Unknown = 1010
}
 Represents enumeration of ConfigurationType used to configure or access certain aspect of logging. More...
enum class  LoggingFlag : base::type::EnumType {
  NewLineForContainer = 1 , AllowVerboseIfModuleNotSpecified = 2 , LogDetailedCrashReason = 4 , DisableApplicationAbortOnFatalLog = 8 ,
  ImmediateFlush = 16 , StrictLogFileSizeCheck = 32 , ColoredTerminalOutput = 64 , MultiLoggerSupport = 128 ,
  DisablePerformanceTrackingCheckpointComparison = 256 , DisableVModules = 512 , DisableVModulesExtensions = 1024 , HierarchicalLogging = 2048 ,
  CreateLoggerAutomatically = 4096 , AutoSpacing = 8192 , FixedTimeFormat = 16384 , IgnoreSigInt = 32768
}
 Flags used while writing logs. This flags are set by user. More...

Variables

static struct StringToLevelItem stringToLevelMap []
static struct ConfigurationStringToTypeItem configStringToTypeMap []
base::debug::CrashHandler elCrashHandler

Detailed Description

Easylogging++ entry namespace.

Typedef Documentation

◆ FormatSpecifierValueResolver

typedef std::function<std::string(const LogMessage*)> el::FormatSpecifierValueResolver

Resolving function for format specifier.

◆ LogBuilderPtr

typedef std::shared_ptr<LogBuilder> el::LogBuilderPtr

◆ PreRollOutCallback

typedef std::function<void(const char*, std::size_t)> el::PreRollOutCallback

Enumeration Type Documentation

◆ Color

enum class el::Color : base::type::EnumType
strong
Enumerator
Default 
Red 
Green 
Yellow 
Blue 
Magenta 
Cyan 

◆ ConfigurationType

Represents enumeration of ConfigurationType used to configure or access certain aspect of logging.

Enumerator
Enabled 

Determines whether or not corresponding level and logger of logging is enabled You may disable all logs by using el::Level::Global.

ToFile 

Whether or not to write corresponding log to log file.

ToStandardOutput 

Whether or not to write corresponding level and logger log to standard output. By standard output meaning termnal, command prompt etc.

Format 

Determines format of logging corresponding level and logger.

Filename 

Determines log file (full path) to write logs to for correponding level and logger.

SubsecondPrecision 

Specifies precision of the subsecond part. It should be within range (1-6).

MillisecondsWidth 

Alias of SubsecondPrecision (for backward compatibility).

PerformanceTracking 

Determines whether or not performance tracking is enabled.

@detail This does not depend on logger or level. Performance tracking always uses 'performance' logger

MaxLogFileSize 

Specifies log file max size.

@detail If file size of corresponding log file (for corresponding level) is >= specified size, log file will be truncated and re-initiated.

LogFlushThreshold 

Specifies number of log entries to hold until we flush pending log data.

Unknown 

Represents unknown configuration.

◆ Level

enum class el::Level : base::type::EnumType
strong

Represents enumeration for severity level used to determine level of logging.

@detail With Easylogging++, developers may disable or enable any level regardless of what the severity is. Or they can choose to log using hierarchical logging flag

Enumerator
Global 

Generic level that represents all the levels. Useful when setting global configuration for all levels.

Trace 

Information that can be useful to back-trace certain events - mostly useful than debug logs.

Debug 

Informational events most useful for developers to debug application.

Fatal 

Severe error information that will presumably abort application.

Error 

Information representing errors in application but application will keep running.

Warning 

Useful when application has potentially harmful situtaions.

Verbose 

Information that can be highly useful and vary with verbose logging level.

Info 

Mainly useful to represent current progress of application.

Unknown 

Represents unknown level.

◆ LoggingFlag

Flags used while writing logs. This flags are set by user.

Enumerator
NewLineForContainer 

Makes sure we have new line for each container log entry.

AllowVerboseIfModuleNotSpecified 

Makes sure if -vmodule is used and does not specifies a module, then verbose logging is allowed via that module.

LogDetailedCrashReason 

When handling crashes by default, detailed crash reason will be logged as well.

DisableApplicationAbortOnFatalLog 

Allows to disable application abortion when logged using FATAL level.

ImmediateFlush 

Flushes log with every log-entry (performance sensative) - Disabled by default.

StrictLogFileSizeCheck 

Enables strict file rolling.

ColoredTerminalOutput 

Make terminal output colorful for supported terminals.

MultiLoggerSupport 

Supports use of multiple logging in same macro, e.g, CLOG(INFO, "default", "network").

DisablePerformanceTrackingCheckpointComparison 

Disables comparing performance tracker's checkpoints.

DisableVModules 

Disable VModules.

DisableVModulesExtensions 

Disable VModules extensions.

HierarchicalLogging 

Enables hierarchical logging.

CreateLoggerAutomatically 

Creates logger automatically when not available.

AutoSpacing 

Adds spaces b/w logs that separated by left-shift operator.

FixedTimeFormat 

Preserves time format and does not convert it to sec, hour etc (performance tracking only).

IgnoreSigInt 

Variable Documentation

◆ configStringToTypeMap

struct ConfigurationStringToTypeItem el::configStringToTypeMap[]
static
Initial value:
= {
{ "to_file", ConfigurationType::ToFile },
{ "to_standard_output", ConfigurationType::ToStandardOutput },
{ "filename", ConfigurationType::Filename },
{ "subsecond_precision", ConfigurationType::SubsecondPrecision },
{ "milliseconds_width", ConfigurationType::MillisecondsWidth },
{ "performance_tracking", ConfigurationType::PerformanceTracking },
{ "max_log_file_size", ConfigurationType::MaxLogFileSize },
{ "log_flush_threshold", ConfigurationType::LogFlushThreshold },
}
@ Enabled
Determines whether or not corresponding level and logger of logging is enabled You may disable all lo...
Definition easylogging++.h:667
@ MillisecondsWidth
Alias of SubsecondPrecision (for backward compatibility).
Definition easylogging++.h:680
@ Filename
Determines log file (full path) to write logs to for correponding level and logger.
Definition easylogging++.h:676
@ MaxLogFileSize
Specifies log file max size.
Definition easylogging++.h:689
@ Format
Determines format of logging corresponding level and logger.
Definition easylogging++.h:674
@ SubsecondPrecision
Specifies precision of the subsecond part. It should be within range (1-6).
Definition easylogging++.h:678
@ ToStandardOutput
Whether or not to write corresponding level and logger log to standard output. By standard output mea...
Definition easylogging++.h:672
@ PerformanceTracking
Determines whether or not performance tracking is enabled.
Definition easylogging++.h:684
@ LogFlushThreshold
Specifies number of log entries to hold until we flush pending log data.
Definition easylogging++.h:691
@ ToFile
Whether or not to write corresponding log to log file.
Definition easylogging++.h:669

◆ elCrashHandler

base::debug::CrashHandler el::elCrashHandler
extern

◆ stringToLevelMap

struct StringToLevelItem el::stringToLevelMap[]
static
Initial value:
= {
{ "global", Level::Global },
{ "debug", Level::Debug },
{ "info", Level::Info },
{ "warning", Level::Warning },
{ "error", Level::Error },
{ "fatal", Level::Fatal },
{ "verbose", Level::Verbose },
{ "trace", Level::Trace }
}
@ Warning
Useful when application has potentially harmful situtaions.
Definition easylogging++.h:603
@ Info
Mainly useful to represent current progress of application.
Definition easylogging++.h:607
@ Global
Generic level that represents all the levels. Useful when setting global configuration for all levels...
Definition easylogging++.h:593
@ Fatal
Severe error information that will presumably abort application.
Definition easylogging++.h:599
@ Error
Information representing errors in application but application will keep running.
Definition easylogging++.h:601
@ Debug
Informational events most useful for developers to debug application.
Definition easylogging++.h:597
@ Verbose
Information that can be highly useful and vary with verbose logging level.
Definition easylogging++.h:605
@ Trace
Information that can be useful to back-trace certain events - mostly useful than debug logs.
Definition easylogging++.h:595