Class ConsoleLogger
- java.lang.Object
-
- com.github.nosan.embedded.cassandra.commons.logging.ConsoleLogger
-
-
Constructor Summary
Constructors Constructor Description ConsoleLogger(String name)CreatesConsoleLoggerwith provided args.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddebug(String message)Log the message from the provided message at debug level.voiddebug(String message, Object... args)Log the message from the provided message at debug level.voiddebug(Throwable throwable, String message)Log the providedThrowableand message at debug level.voiddebug(Throwable throwable, String message, Object... args)Log the providedThrowableand message at debug level.voiderror(String message)Log the message from the provided message at error level.voiderror(String message, Object... args)Log the message from the provided message at error level.voiderror(Throwable throwable, String message)Log the providedThrowableand message at error level.voiderror(Throwable throwable, String message, Object... args)Log the providedThrowableand message at error level.StringgetName()Gets the name of thisLoggerinstance.voidinfo(String message)Log the message from the provided at info level.voidinfo(String message, Object... args)Log the message from the provided at info level.voidinfo(Throwable throwable, String message)Log the providedThrowableand message at info level.voidinfo(Throwable throwable, String message, Object... args)Log the providedThrowableand message at info level.booleanisDebugEnabled()Is the logger instance enabled for the DEBUG level.booleanisErrorEnabled()Is the logger instance enabled for the ERROR level.booleanisInfoEnabled()Is the logger instance enabled for the INFO level.booleanisTraceEnabled()Is the logger instance enabled for the TRACE level.booleanisWarnEnabled()Is the logger instance enabled for the WARN level.voidtrace(String message)Log the message from the provided message at trace level.voidtrace(String message, Object... args)Log the message from the provided message at trace level.voidtrace(Throwable throwable, String message)Log the providedThrowableand message at trace level.voidtrace(Throwable throwable, String message, Object... args)Log the providedThrowableand message at trace level.voidwarn(String message)Log the message from the provided message at warn level.voidwarn(String message, Object... args)Log the message from the provided message at warn level.voidwarn(Throwable throwable, String message)Log the providedThrowableand message at warn level.voidwarn(Throwable throwable, String message, Object... args)Log the providedThrowableand message at warn level.
-
-
-
Constructor Detail
-
ConsoleLogger
public ConsoleLogger(String name)
CreatesConsoleLoggerwith provided args.- Parameters:
name- the logger name
-
-
Method Detail
-
error
public void error(String message, Object... args)
Description copied from interface:LoggerLog the message from the provided message at error level.- Specified by:
errorin interfaceLogger- Parameters:
message- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
error
public void error(Throwable throwable, String message)
Description copied from interface:LoggerLog the providedThrowableand message at error level.
-
error
public void error(Throwable throwable, String message, Object... args)
Description copied from interface:LoggerLog the providedThrowableand message at error level.- Specified by:
errorin interfaceLogger- Parameters:
throwable- the exception (throwable) to be loggedmessage- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
getName
public String getName()
Description copied from interface:LoggerGets the name of thisLoggerinstance.
-
isErrorEnabled
public boolean isErrorEnabled()
Description copied from interface:LoggerIs the logger instance enabled for the ERROR level.- Specified by:
isErrorEnabledin interfaceLogger- Returns:
trueif this Logger is enabled for the ERROR level
-
error
public void error(String message)
Description copied from interface:LoggerLog the message from the provided message at error level.
-
warn
public void warn(String message, Object... args)
Description copied from interface:LoggerLog the message from the provided message at warn level.- Specified by:
warnin interfaceLogger- Parameters:
message- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
warn
public void warn(Throwable throwable, String message)
Description copied from interface:LoggerLog the providedThrowableand message at warn level.
-
warn
public void warn(Throwable throwable, String message, Object... args)
Description copied from interface:LoggerLog the providedThrowableand message at warn level.- Specified by:
warnin interfaceLogger- Parameters:
throwable- the exception (throwable) to be loggedmessage- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
isWarnEnabled
public boolean isWarnEnabled()
Description copied from interface:LoggerIs the logger instance enabled for the WARN level.- Specified by:
isWarnEnabledin interfaceLogger- Returns:
trueif this Logger is enabled for the WARN level
-
warn
public void warn(String message)
Description copied from interface:LoggerLog the message from the provided message at warn level.
-
info
public void info(String message, Object... args)
Description copied from interface:LoggerLog the message from the provided at info level.- Specified by:
infoin interfaceLogger- Parameters:
message- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
info
public void info(Throwable throwable, String message)
Description copied from interface:LoggerLog the providedThrowableand message at info level.
-
info
public void info(Throwable throwable, String message, Object... args)
Description copied from interface:LoggerLog the providedThrowableand message at info level.- Specified by:
infoin interfaceLogger- Parameters:
throwable- the exception (throwable) to be loggedmessage- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
isInfoEnabled
public boolean isInfoEnabled()
Description copied from interface:LoggerIs the logger instance enabled for the INFO level.- Specified by:
isInfoEnabledin interfaceLogger- Returns:
trueif this Logger is enabled for the INFO level
-
info
public void info(String message)
Description copied from interface:LoggerLog the message from the provided at info level.
-
debug
public void debug(String message, Object... args)
Description copied from interface:LoggerLog the message from the provided message at debug level.- Specified by:
debugin interfaceLogger- Parameters:
message- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
debug
public void debug(Throwable throwable, String message)
Description copied from interface:LoggerLog the providedThrowableand message at debug level.
-
debug
public void debug(Throwable throwable, String message, Object... args)
Description copied from interface:LoggerLog the providedThrowableand message at debug level.- Specified by:
debugin interfaceLogger- Parameters:
throwable- the exception (throwable) to be loggedmessage- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
isDebugEnabled
public boolean isDebugEnabled()
Description copied from interface:LoggerIs the logger instance enabled for the DEBUG level.- Specified by:
isDebugEnabledin interfaceLogger- Returns:
trueif this Logger is enabled for the DEBUG level
-
debug
public void debug(String message)
Description copied from interface:LoggerLog the message from the provided message at debug level.
-
trace
public void trace(String message, Object... args)
Description copied from interface:LoggerLog the message from the provided message at trace level.- Specified by:
tracein interfaceLogger- Parameters:
message- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
trace
public void trace(Throwable throwable, String message)
Description copied from interface:LoggerLog the providedThrowableand message at trace level.
-
trace
public void trace(Throwable throwable, String message, Object... args)
Description copied from interface:LoggerLog the providedThrowableand message at trace level.- Specified by:
tracein interfaceLogger- Parameters:
throwable- the exception (throwable) to be loggedmessage- the pattern stringargs- object(s) to format- See Also:
MessageFormat.format(String, Object...)
-
isTraceEnabled
public boolean isTraceEnabled()
Description copied from interface:LoggerIs the logger instance enabled for the TRACE level.- Specified by:
isTraceEnabledin interfaceLogger- Returns:
trueif this Logger is enabled for the TRACE level
-
-