package
0.21.1
Repository: https://github.com/teitei-tk/cmd.git
Documentation: pkg.go.dev

# Functions

No description provided by the author
Adds in a context called `caller` to the record (contains file name and line number like `foo.go:12`) Uses the `log15.CallerFuncHandler` to perform this task.
Filter handler.
FormatFunc returns a new Format object which uses the given function to perform record formatting.
Function handler wraps the declared function and returns the handler for it.
Returns the logger for the name.
This function allows you to do a full declaration for the log, it is recommended you use FuncHandler instead.
No description provided by the author
JsonFormatEx formats log records as JSON objects.
LazyHandler writes all values to the wrapped handler after evaluating any lazy functions in the record's context.
Filters out records which do not match the level Uses the `log15.FilterHandler` to perform this task.
If match then A handler is called otherwise B handler is called.
MatchFilterHandler returns a Handler that only writes records to the wrapped Handler if the given key in the logged context matches the value.
Filters out records which match the key value pair Uses the `log15.MatchFilterHandler` to perform this task.
Match all values in map to log.
Filters out records which do not match the level Uses the `log15.FilterHandler` to perform this task.
No description provided by the author
Create a new logger.
For logging purposes the call stack can be used to record the stack trace of a bad error simply pass it as a context field in your log statement like `controller.Log.Crit("This should not occur","stack",revel.NewCallStack())`.
No description provided by the author
Create a new list of log handlers.
Create a new log options.
Create a new parent log handler.
No description provided by the author
The nil handler is used if logging for a specific request needs to be turned off.
Filters out records which match the level Uses the `log15.FilterHandler` to perform this task.
Filters out records which do not match the key value pair Uses the `log15.FilterHandler` to perform this task.
Match !(Match all values in map to log) The inverse of MatchMapHandler.
Set the systems default logger Default logs will be captured and handled by revel at level info.
StreamHandler writes log records to an io.Writer with the given format.
SyncHandler can be wrapped around a handler to guarantee that only a single Log operation can proceed at a time.
Outputs to the terminal in a format like below INFO 09:11:32 server-engine.go:169: Request Stats.

# Constants

Critical.
Debug.
Error.
Information.
Warning.
The special use flag enables showing messages when the logger is setup.
The test mode flag overrides the default log level and shows only errors.

# Variables

The log function map can be added to, so that you can specify your own logging mechanism it has defaults for off, stdout, stderr.
A list of all the log levels.

# Structs

No description provided by the author
The LogHandler defines the interface to handle the log records.
No description provided by the author
List log handler handles a list of LogHandlers.
The LogHandler defines the interface to handle the log records.
The LogHandler defines the interface to handle the log records.
This type implements the MultiLogger.

# Interfaces

The LogHandler defines the interface to handle the log records.
The LogHandler defines the interface to handle the log records.
The LogHandler defines the interface to handle the log records.
The LogHandler defines the interface to handle the log records.
The LogHandler defines the interface to handle the log records.
The LogHandler defines the interface to handle the log records.

# Type aliases

Internally used contextMap, allows conversion of map to map[string]string.
The LogHandler defines the interface to handle the log records.