Class: Logger

Logger


new Logger(notifier, options)

Parameters:
Name Type Description
notifier Notifier
options

Methods


alert(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

canLog(severity)

Parameters:
Name Type Description
severity Severity
Returns:
boolean

critical(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

debug(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

emergency(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

error(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

getChannel()

Returns:
Type
string

getLevel()

Returns:
number

getUser()

Returns:
Type
string

info(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

isEnabled()

Returns:
enabled
Type
boolean

log(message, data, level, channel)

Parameters:
Name Type Default Description
message string
data mixed null
level int | Severity , standard RFC3164 code (https://tools.ietf.org/html/rfc3164)
channel string

notice(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string

setChannel(channel)

Parameters:
Name Type Description
channel string

setColor({Boolean})

Parameters:
Name Type Description
{Boolean} val

setEnabled(enabled)

Parameters:
Name Type Description
enabled boolean

setFormatter(formatter)

Parameters:
Name Type Description
formatter Formatter

setLevel(level)

Parameters:
Name Type Description
level number

setUser(user)

Parameters:
Name Type Description
user string

showLineNumbers(show)

Parameters:
Name Type Description
show boolean

warning(message, data, channel)

Parameters:
Name Type Default Description
message string
data any null
channel string