Package software.amazon.awssdk.utils
Class Logger
java.lang.Object
software.amazon.awssdk.utils.Logger
-
Method Summary
Modifier and TypeMethodDescriptionvoidChecks if debug is enabled and if so logs the supplied messagevoidChecks if debug is enabled and if so logs the supplied message and exceptionvoidChecks if error is enabled and if so logs the supplied messagevoidChecks if error is enabled and if so logs the supplied message and exceptionvoidChecks if info is enabled and if so logs the supplied messagevoidChecks if info is enabled and if so logs the supplied message and exceptionbooleanisLoggingLevelEnabled(String logLevel) Determines if the log-level passed is enabledbooleanisLoggingLevelEnabled(org.slf4j.event.Level logLevel) Determines if the provided log-level is enabled.voidLog a message at the given log level (if it is enabled).org.slf4j.Loggerlogger()static LoggerStatic factory to get a logger instance for a given classstatic LoggerStatic factory to get a logger instance with a specific name.voidChecks if trace is enabled and if so logs the supplied messagevoidChecks if trace is enabled and if so logs the supplied message and exceptionvoidChecks if warn is enabled and if so logs the supplied messagevoidChecks if warn is enabled and if so logs the supplied message and exception
-
Method Details
-
logger
public org.slf4j.Logger logger() -
info
Checks if info is enabled and if so logs the supplied message- Parameters:
msg- - supplier for the log message
-
info
Checks if info is enabled and if so logs the supplied message and exception- Parameters:
msg- - supplier for the log messagethrowable- - a throwable to log
-
error
Checks if error is enabled and if so logs the supplied message- Parameters:
msg- - supplier for the log message
-
error
Checks if error is enabled and if so logs the supplied message and exception- Parameters:
msg- - supplier for the log messagethrowable- - a throwable to log
-
debug
Checks if debug is enabled and if so logs the supplied message- Parameters:
msg- - supplier for the log message
-
debug
Checks if debug is enabled and if so logs the supplied message and exception- Parameters:
msg- - supplier for the log messagethrowable- - a throwable to log
-
warn
Checks if warn is enabled and if so logs the supplied message- Parameters:
msg- - supplier for the log message
-
warn
Checks if warn is enabled and if so logs the supplied message and exception- Parameters:
msg- - supplier for the log messagethrowable- - a throwable to log
-
trace
Checks if trace is enabled and if so logs the supplied message- Parameters:
msg- - supplier for the log message
-
trace
Checks if trace is enabled and if so logs the supplied message and exception- Parameters:
msg- - supplier for the log messagethrowable- - a throwable to log
-
isLoggingLevelEnabled
public boolean isLoggingLevelEnabled(org.slf4j.event.Level logLevel) Determines if the provided log-level is enabled.- Parameters:
logLevel- the SLF4J log level enum- Returns:
- whether that level is enabled
-
isLoggingLevelEnabled
Determines if the log-level passed is enabled- Parameters:
logLevel- a string representation of the log level, e.g. "debug"- Returns:
- whether or not that level is enable
-
log
Log a message at the given log level (if it is enabled).- Parameters:
logLevel- the SLF4J log levelmsg- supplier for the log message
-
loggerFor
Static factory to get a logger instance for a given class- Parameters:
clz- - class to get the logger for- Returns:
- a Logger instance
-
loggerFor
Static factory to get a logger instance with a specific name.- Parameters:
name- - The name of the logger to create- Returns:
- a Logger instance
-