ViewerLogger

Inheritance: java.lang.Object

public class ViewerLogger

Global viewer logger Implements logging messages to integrated or user defined logger.

Constructors

Constructor Description
ViewerLogger()

Methods

Method Description
trace(String message, Object[] arguments) Trace message
trace(Throwable throwable, String message, Object[] arguments) Trace message
isTraceEnabled() Checks is trace logging enabled
debug(String message, Object[] arguments) Debug message
debug(Throwable throwable, String message, Object[] arguments) Debug message
isDebugEnabled() Checks is debug logging enabled
warning(String message, Object[] arguments) Warning message
warning(Throwable throwable, String message, Object[] arguments) Warning message
isWarningEnabled() Checks is warning logging enabled
error(String message, Object[] arguments) Error message
error(Throwable throwable, String message, Object[] arguments) Error message
isErrorEnabled() Checks is error logging enabled
getLogger()
setLogger(ILogger logger) Sets the logger.

ViewerLogger()

public ViewerLogger()

trace(String message, Object[] arguments)

public static void trace(String message, Object[] arguments)

Trace message

Parameters:

Parameter Type Description
message java.lang.String The trace message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

trace(Throwable throwable, String message, Object[] arguments)

public static void trace(Throwable throwable, String message, Object[] arguments)

Trace message

Parameters:

Parameter Type Description
throwable java.lang.Throwable The exception message
message java.lang.String The trace message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

isTraceEnabled()

public static boolean isTraceEnabled()

Checks is trace logging enabled

Returns: boolean - true if enabled

debug(String message, Object[] arguments)

public static void debug(String message, Object[] arguments)

Debug message

Parameters:

Parameter Type Description
message java.lang.String The debug message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

debug(Throwable throwable, String message, Object[] arguments)

public static void debug(Throwable throwable, String message, Object[] arguments)

Debug message

Parameters:

Parameter Type Description
throwable java.lang.Throwable The exception message
message java.lang.String The debug message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

isDebugEnabled()

public static boolean isDebugEnabled()

Checks is debug logging enabled

Returns: boolean - true if enabled

warning(String message, Object[] arguments)

public static void warning(String message, Object[] arguments)

Warning message

Parameters:

Parameter Type Description
message java.lang.String The warning message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

warning(Throwable throwable, String message, Object[] arguments)

public static void warning(Throwable throwable, String message, Object[] arguments)

Warning message

Parameters:

Parameter Type Description
throwable java.lang.Throwable The exception message
message java.lang.String The warning message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

isWarningEnabled()

public static boolean isWarningEnabled()

Checks is warning logging enabled

Returns: boolean - true if enabled

error(String message, Object[] arguments)

public static void error(String message, Object[] arguments)

Error message

Parameters:

Parameter Type Description
message java.lang.String The error message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

error(Throwable throwable, String message, Object[] arguments)

public static void error(Throwable throwable, String message, Object[] arguments)

Error message

Parameters:

Parameter Type Description
throwable java.lang.Throwable The exception message
message java.lang.String The error message, can contains {} to be replaced with arguments
arguments java.lang.Object[] The arguments, replaces {} in message in order of passing

isErrorEnabled()

public static boolean isErrorEnabled()

Checks is error logging enabled

Returns: boolean - true if enabled

getLogger()

public static synchronized ILogger getLogger()

Returns: com.groupdocs.foundation.logging.ILogger

setLogger(ILogger logger)

public static synchronized void setLogger(ILogger logger)

Sets the logger.

Parameters:

Parameter Type Description
logger com.groupdocs.foundation.logging.ILogger The input logger.