public final class Console extends Object
| Modifier and Type | Method and Description |
|---|---|
static void |
debug(Object message)
If not in production mode, logs the given message to the browser console
using the debug log level.
|
static void |
error(Object message)
If not in production mode, logs the given message to the browser console
using the error log level.
|
static void |
log(Object message)
If not in production mode, logs the given message to the browser console
using the info log level.
|
static void |
reportStacktrace(Exception exception)
Logs the stacktrace of an exception to the browser console.
|
static void |
setProductionMode(boolean isProductionMode)
Changes logger behavior, making it skip all browser logging for
production mode.
|
static void |
warn(Object message)
If not in production mode, logs the given message to the browser console
using the warning log level.
|
public static void setProductionMode(boolean isProductionMode)
isProductionMode - if an application is in the production mode or notpublic static void debug(Object message)
If used directly in a JVM, writes the message to standard output disregarding of the production mode settings.
message - the message to logpublic static void log(Object message)
If used directly in a JVM, writes the message to standard output disregarding of the production mode settings.
message - the message to logpublic static void warn(Object message)
If used directly in a JVM, writes the message to standard error disregarding of the production mode settings.
message - the message to logpublic static void error(Object message)
If used directly in a JVM, writes the message to standard error disregarding of the production mode settings.
message - the message to logpublic static void reportStacktrace(Exception exception)
exception - the exception for whichCopyright © 2000–2022 Vaadin Ltd. All rights reserved.