1
1
Fork 0
mirror of https://github.com/boxgaming/qbjs.git synced 2024-05-12 08:00:12 +00:00
4 Console.LogLevel
boxgaming edited this page 2023-09-25 13:41:18 -05:00

Gets or sets the current console log level.

Syntax

logLevel& = Console.LogLevel
Console.LogLevel logLevel&

The following log levels can be set with this method:
NONE, FATAL, ERROR, WARN, INFO, DEBUG, TRACE, ALL

Calls to Console.Log of equal or greater severity will be written to the console output. For example, if the log level is set to WARN, all messages logged at WARN, ERROR and FATAL will be displayed in the console while INFO, DEBUG and TRACE messages will be ignored.

Examples

Example 1: Set the log level to DEBUG.

Import Console From "lib/web/console.bas"

Console.LogLevel Console.DEBUG

Console.Log "This is an info message.", Console.INFO
Console.Log "This is a trace message, it will be ignored.", Console.TRACE

See Also

Console.Log