public class Log
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static OutputChannel |
SYSTEM_OUT
OutputChannel implementation based on System.out.
|
Constructor and Description |
---|
Log(OutputChannel outputChannel)
Creates a new instance of the class using defaults
|
Log(OutputChannel outputChannel,
LogLevel currentLogLevel,
java.lang.String tag)
Creates a new instance of the class
|
Modifier and Type | Method and Description |
---|---|
void |
assrt(java.lang.String message)
Assert level logging
|
void |
assrt(java.lang.String template,
java.lang.Object... args)
Assert level logging in a parameterized string
|
void |
debug(java.lang.String message)
Debug logging
|
void |
debug(java.lang.String template,
java.lang.Object... args)
Debug level logging in a parameterized string
|
void |
error(java.lang.String message)
Error level logging
|
void |
error(java.lang.String template,
java.lang.Object... args)
Error level logging in a parameterized string
|
void |
exception(java.lang.Throwable e)
Logs an exception
|
void |
exception(java.lang.Throwable e,
java.lang.String template,
java.lang.Object... args) |
void |
info(java.lang.String message)
Information level logging
|
void |
info(java.lang.String template,
java.lang.Object... args)
Information level logging in a parameterized string
|
void |
log(LogLevel logLevel,
java.lang.String message)
Basic logging function with a single string message
|
void |
log(LogLevel logLevel,
java.lang.String template,
java.lang.Object... args)
Parameterized versions of the logging functions
|
void |
setCurrentLogLevel(LogLevel logLevel)
Sets the current logging level
|
void |
setPackagePrefix()
Sets the tag with the package name prefix
|
void |
verbose(java.lang.String message)
Verbose logging
|
void |
verbose(java.lang.String template,
java.lang.Object... args)
Verbose level logging in a parameterized string
|
void |
warn(java.lang.String message)
Warning level logging
|
void |
warn(java.lang.String template,
java.lang.Object... args)
Warning level logging in a parameterized string
|
public static final OutputChannel SYSTEM_OUT
public Log(OutputChannel outputChannel)
outputChannel
- An interface to OutputChannel
to uze for messages.public Log(OutputChannel outputChannel, LogLevel currentLogLevel, java.lang.String tag)
outputChannel
- An interface to OutputChannel
to uze for messages.currentLogLevel
- Current log level for loggingtag
- Base tag to use for messagespublic void setCurrentLogLevel(LogLevel logLevel)
logLevel
- Log level to filterpublic void setPackagePrefix()
public void log(LogLevel logLevel, java.lang.String message)
logLevel
- Log levelmessage
- Message to logpublic void log(LogLevel logLevel, java.lang.String template, java.lang.Object... args)
logLevel
- Log leveltemplate
- String templateargs
- Argumentspublic void verbose(java.lang.String message)
message
- Message to logpublic void verbose(java.lang.String template, java.lang.Object... args)
template
- Parameterized stringargs
- Argumentspublic void debug(java.lang.String message)
message
- Message to logpublic void debug(java.lang.String template, java.lang.Object... args)
template
- Parameterized stringargs
- Argumentspublic void info(java.lang.String message)
message
- Message to logpublic void info(java.lang.String template, java.lang.Object... args)
template
- Parameterized stringargs
- Argumentspublic void warn(java.lang.String message)
message
- Message to logpublic void warn(java.lang.String template, java.lang.Object... args)
template
- Parameterized stringargs
- Argumentspublic void error(java.lang.String message)
message
- Message to logpublic void error(java.lang.String template, java.lang.Object... args)
template
- Parameterized stringargs
- Argumentspublic void assrt(java.lang.String message)
message
- Message to logpublic void assrt(java.lang.String template, java.lang.Object... args)
template
- Parameterized stringargs
- Argumentspublic void exception(java.lang.Throwable e)
e
- Exception to logpublic void exception(java.lang.Throwable e, java.lang.String template, java.lang.Object... args)
Copyright © 2018 Amazon Web Services, Inc. All Rights Reserved.