public class BasicLevel
extends java.lang.Object
This class predefines a set of levels. Indeed during the instrumentation, developers must write calls to log an event with a specific level. One of the goals of Monolog is to be independent of the logging implementation. To respect this goal, predefined variables or constants are needed. This class contains only static but not final variables to represent these predefined levels.
To respect the flyweight pattern chosen in monolog specification, for each predefined level, a Level variable and an integer variable are declared. Their values are not defined, in order to leave it to the implementation to set them.
This class defines five basic levels. But it is possible to a MonoLog user to define additional levels. Monolog allows this type of extension with some constraints or advices:
Modifier and Type | Field and Description |
---|---|
static int |
DEBUG
DEBUG messages might include things like minor (recoverable) failures.
|
static int |
ERROR
The ERROR level designates error events that might still allow the
application to continue running.
|
static int |
FATAL
In general, FATAL messages should describe events that are of
considerable importance and which will prevent continuation of the
program execution.
|
static int |
INFO
The INFO level designates informational messages that highlight the
progress of the application at a coarse-grained level.
|
static int |
INHERIT
This special level indicates that the level is inherited from its
ancestors.
|
static Level |
LEVEL_DEBUG
DEBUG messages might include things like minor (recoverable) failures.
|
static Level |
LEVEL_ERROR
The ERROR level designates error events that might still allow the
application to continue running.
|
static Level |
LEVEL_FATAL
In general, FATAL messages should describe events that are of
considerable importance and which will prevent continuation of the
program execution.
|
static Level |
LEVEL_INFO
The INFO level designates informational messages that highlight the
progress of the application at a coarse-grained level.
|
static Level |
LEVEL_INHERIT
This special level indicates that the level is inherited from its
ancestors.
|
static Level |
LEVEL_WARN
In general, WARN messages should describe events that will be of
interest to end users or system managers, or which indicate potential
problems.
|
static int |
WARN
In general, WARN messages should describe events that will be of
interest to end users or system managers, or which indicate potential
problems.
|
Constructor and Description |
---|
BasicLevel() |
public static int FATAL
public static Level LEVEL_FATAL
public static int ERROR
public static Level LEVEL_ERROR
public static int WARN
public static Level LEVEL_WARN
public static int INFO
public static Level LEVEL_INFO
public static int DEBUG
public static Level LEVEL_DEBUG
public static int INHERIT
public static Level LEVEL_INHERIT