Electroneum
el Namespace Reference

Easylogging++ entry namespace. More...

Namespaces

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

Classes

class  Callback
 
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  ConfigurationTypeHelper
 Static class that contains helper functions for el::ConfigurationType. More...
 
class  CustomFormatSpecifier
 User-provided custom format specifier. More...
 
class  Helpers
 Static helpers for developers. More...
 
class  LevelHelper
 Static class that contains helper functions for el::Level. More...
 
class  LogBuilder
 
class  LogDispatchCallback
 
class  LogDispatchData
 
class  Loggable
 Base of Easylogging++ friendly class. More...
 
class  Logger
 Represents a logger holding ID and configurations we need to write logs. More...
 
class  LoggerRegistrationCallback
 
class  Loggers
 Static helpers to deal with loggers and their configurations. More...
 
class  LogMessage
 
class  PerformanceTrackingCallback
 
class  SysLogInitializer
 Initializes syslog with process ID, options and facility. calls closelog() on d'tor. 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. More...
 
typedef std::shared_ptr< LogBuilderLogBuilderPtr
 

Enumerations

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

Variables

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.

Definition at line 1665 of file easylogging++.h.

◆ LogBuilderPtr

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

Definition at line 2231 of file easylogging++.h.

◆ PreRollOutCallback

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

Definition at line 824 of file easylogging++.h.

Enumeration Type Documentation

◆ 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.

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

MaxLogFileSize 

Specifies log file max size.

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.

Definition at line 649 of file easylogging++.h.

652  Enabled = 1,
654  ToFile = 2,
657  ToStandardOutput = 4,
659  Format = 8,
661  Filename = 16,
663  SubsecondPrecision = 32,
669  PerformanceTracking = 64,
674  MaxLogFileSize = 128,
676  LogFlushThreshold = 256,
678  Unknown = 1010
679 };
Specifies precision of the subsecond part. It should be within range (1-6).
Determines whether or not corresponding level and logger of logging is enabled You may disable all lo...
Determines whether or not performance tracking is enabled.
SubsecondPrecision MillisecondsWidth
Type alias of SubsecondPrecision.
Represents unknown level.
Determines log file (full path) to write logs to for correponding level and logger.
Determines format of logging corresponding level and logger.
unsigned int EnumType
Specifies number of log entries to hold until we flush pending log data.
Whether or not to write corresponding log to log file.
Whether or not to write corresponding level and logger log to standard output. By standard output mea...
Specifies log file max size.

◆ Level

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

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.

Definition at line 585 of file easylogging++.h.

587  Global = 1,
589  Trace = 2,
591  Debug = 4,
593  Fatal = 8,
595  Error = 16,
597  Warning = 32,
599  Verbose = 64,
601  Info = 128,
603  Unknown = 1010
604 };
Information representing errors in application but application will keep running. ...
Informational events most useful for developers to debug application.
Severe error information that will presumably abort application.
Represents unknown level.
Information that can be highly useful and vary with verbose logging level.
unsigned int EnumType
Useful when application has potentially harmful situtaions.
Mainly useful to represent current progress of application.
Generic level that represents all the levels. Useful when setting global configuration for all levels...
Information that can be useful to back-trace certain events - mostly useful than debug logs...

◆ 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 

Definition at line 710 of file easylogging++.h.

721  ImmediateFlush = 16,
727  MultiLoggerSupport = 128,
731  DisableVModules = 512,
735  HierarchicalLogging = 2048,
739  AutoSpacing = 8192,
741  FixedTimeFormat = 16384,
742  // @brief Ignore SIGINT or crash
743  IgnoreSigInt = 32768,
744 };
Creates logger automatically when not available.
Makes sure we have new line for each container log entry.
Disables comparing performance tracker&#39;s checkpoints.
Adds spaces b/w logs that separated by left-shift operator.
Makes sure if -vmodule is used and does not specifies a module, then verbose logging is allowed via t...
Disable VModules extensions.
Preserves time format and does not convert it to sec, hour etc (performance tracking only) ...
unsigned int EnumType
Make terminal output colorful for supported terminals.
When handling crashes by default, detailed crash reason will be logged as well.
Enables strict file rolling.
Flushes log with every log-entry (performance sensative) - Disabled by default.
Enables hierarchical logging.
Supports use of multiple logging in same macro, e.g, CLOG(INFO, "default", "network") ...
Allows to disable application abortion when logged using FATAL level.

Variable Documentation

◆ elCrashHandler

base::debug::CrashHandler el::elCrashHandler