The Logger class serves as the core element for the logging system.
Arguments
- path
character vector, a path to the log file to use
- con
(optional) connection to a file
- verbose
logical, whether R should report extra information on progress
- level
character vector, the log level of the logger. Levels are a mechanism to categorise the severity of an event. Eight levels are supported:
"OFF"indicates the logger is inactive
"FATAL"indicates a fatal event in the application that prevents it from running
"ERROR"indicates an error in the application, possibly recoverable
"WARN"indicates an event that might lead to an error
"INFO"indicates informational messages
"DEBUG"indicates general debugging messages
"TRACE"indicates fine-grained debug events
"ALL"all levels are considered
Levels are considered ordered:
OFF < FATAL < ERROR < WARN < INFO < DEBUG < TRACE < ALLFor example, if we set the level of a logger to
DEBUG, then allINFO,WARN,ERROR, andFATALevents will be logged.