Skip to main content

Class: ConsoleLogger

Default logger which logs to stdout and stderr

Implements

Constructors

new ConsoleLogger()

new ConsoleLogger(): ConsoleLogger

Returns

ConsoleLogger

Defined in

index.ts:88

Methods

debug()

debug(...msg): void

Log a debug message

Parameters

• ...msg: any[]

Returns

void

Implementation of

Logger.debug

Defined in

index.ts:115


error()

error(...msg): void

Log an error message

Parameters

• ...msg: any[]

Returns

void

Implementation of

Logger.error

Defined in

index.ts:145


getLevel()

getLevel(): LogLevel

Return the current LogLevel.

Returns

LogLevel

Implementation of

Logger.getLevel

Defined in

index.ts:93


info()

info(...msg): void

Log an info message

Parameters

• ...msg: any[]

Returns

void

Implementation of

Logger.info

Defined in

index.ts:125


setLevel()

setLevel(level): void

Sets the instance's log level so that only messages which are equal or more severe are output to the console.

Parameters

level: LogLevel

Returns

void

Implementation of

Logger.setLevel

Defined in

index.ts:100


setName()

setName(name): void

Set the instance's name, which will appear on each log line before the message.

Parameters

name: string

Returns

void

Implementation of

Logger.setName

Defined in

index.ts:107


warn()

warn(...msg): void

Log a warning message

Parameters

• ...msg: any[]

Returns

void

Implementation of

Logger.warn

Defined in

index.ts:135