log

Methods
12
Fields
None

Getting one

log

Methods

MethodReturnsDescription
trace(string?, ...any)()Write a trace line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an ar…
debug(string?, ...any)()Write a debug line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an ar…
info(string?, ...any)()Write an info line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an ar…
warn(string?, ...any)()Write a warning line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an…
error(string?, ...any)()Write an error line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an a…
isTraceEnabled()booleanWhether trace lines are written: the level (log:getLevel()) is trace or below. false by default: the level starts at INFO.
isDebugEnabled()booleanWhether debug lines are written: the level (log:getLevel()) is debug or below. false by default: the level starts at INFO.
isInfoEnabled()booleanWhether info lines are written: the level (log:getLevel()) is info or below. true by default: the level starts at INFO.
isWarnEnabled()booleanWhether warning lines are written: the level (log:getLevel()) is warning or below. true by default: the level starts at INFO.
isErrorEnabled()booleanWhether error lines are written: the level (log:getLevel()) is error or below. true by default: the level starts at INFO.
getLevel()stringThe level every plugin's log writes at and above, by name ("INFO" by default; "DEBUG" under the host's BENTO_DEBUG=1).
setLevel(string?)stringSet the level every plugin's log writes at and above to the one level names (ALL, TRACE, DEBUG, INFO, WARN, ERROR, OFF, a…

Method details

trace

trace: (Logger, string?, ...any) -> ()

Write a trace line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an argument is written as tostring writes it, nil as null). An argument no {} took is the error: the last one is written on the next line, as SLF4J writes a Throwable (log:warn("Unable to load", err)).

debug

debug: (Logger, string?, ...any) -> ()

Write a debug line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an argument is written as tostring writes it, nil as null). An argument no {} took is the error: the last one is written on the next line, as SLF4J writes a Throwable (log:warn("Unable to load", err)).

info

info: (Logger, string?, ...any) -> ()

Write an info line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an argument is written as tostring writes it, nil as null). An argument no {} took is the error: the last one is written on the next line, as SLF4J writes a Throwable (log:warn("Unable to load", err)).

warn

warn: (Logger, string?, ...any) -> ()

Write a warning line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an argument is written as tostring writes it, nil as null). An argument no {} took is the error: the last one is written on the next line, as SLF4J writes a Throwable (log:warn("Unable to load", err)).

error

error: (Logger, string?, ...any) -> ()

Write an error line: format with each {} replaced by the next argument, SLF4J's way (a {} after a backslash is written as it is; an argument is written as tostring writes it, nil as null). An argument no {} took is the error: the last one is written on the next line, as SLF4J writes a Throwable (log:warn("Unable to load", err)).

isTraceEnabled

isTraceEnabled: (Logger) -> boolean

Whether trace lines are written: the level (log:getLevel()) is trace or below. false by default: the level starts at INFO.

isDebugEnabled

isDebugEnabled: (Logger) -> boolean

Whether debug lines are written: the level (log:getLevel()) is debug or below. false by default: the level starts at INFO.

isInfoEnabled

isInfoEnabled: (Logger) -> boolean

Whether info lines are written: the level (log:getLevel()) is info or below. true by default: the level starts at INFO.

isWarnEnabled

isWarnEnabled: (Logger) -> boolean

Whether warning lines are written: the level (log:getLevel()) is warning or below. true by default: the level starts at INFO.

isErrorEnabled

isErrorEnabled: (Logger) -> boolean

Whether error lines are written: the level (log:getLevel()) is error or below. true by default: the level starts at INFO.

getLevel

getLevel: (Logger) -> string

The level every plugin's log writes at and above, by name ("INFO" by default; "DEBUG" under the host's BENTO_DEBUG=1).

setLevel

setLevel: (Logger, string?) -> string

Set the level every plugin's log writes at and above to the one level names (ALL, TRACE, DEBUG, INFO, WARN, ERROR, OFF, any case), or keep it for any other name or nil; answers the level now set. It holds for the process until set again.