Package com.nagra.das.sdk
Class DasLog
- java.lang.Object
-
- com.nagra.das.sdk.DasLog
-
public final class DasLog extends Object
Class to control logs produced by the Das SDK
-
-
Field Summary
Fields Modifier and Type Field Description static StringENTERstatic StringENTER_AND_LEAVEstatic StringLEAVEstatic intLOG_LEVEL_DEBUGDebug log levelstatic intLOG_LEVEL_INFOInfo log levelstatic intLOG_LEVEL_VERBOSEVerbose log level
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidalways(String tag, String msg)Logs an unblocked Info message.
This message cannot be blocked by setting a log level.static voidcheckTag(String tag)static voidd(String tag, String msg)Logs a Debug message.
Will only log this message if log level is set to 2 or higher.static voidd(String tag, String msg, Throwable tr)Logs a Debug message.
Will only log this message if log level is set to 2 or higher.static voide(String tag, String msg)Logs an Error message.static voide(String tag, String msg, Throwable tr)Logs an Error message.static voidi(String tag, String msg)Logs an Info message.
Will only log this message if log level is set to 1 or higher.static voidi(String tag, String msg, Throwable tr)Logs an Info message.
Will only log this message if log level is set to 1 or higher.static intlogLevel()Returns the currently set logging level (threshold)static voidlongMessage(String tag, String msg)static voidsetLogLevel(int logLevel)Sets the logging level (threshold).
Valid values:
1 - Info level
2 - Debug level
3 - Verbose levelstatic voidv(String tag, String msg)Logs a Verbose message.
Will only log this message if log level is set to 3.static voidv(String tag, String msg, Throwable tr)Logs a Verbose message.
Will only log this message if log level is set to 3.static voidw(String tag, String msg)Logs a Warning message.static voidw(String tag, String msg, Throwable tr)Logs a Warning message.
-
-
-
Field Detail
-
ENTER
public static final String ENTER
- See Also:
- Constant Field Values
-
LEAVE
public static final String LEAVE
- See Also:
- Constant Field Values
-
ENTER_AND_LEAVE
public static final String ENTER_AND_LEAVE
- See Also:
- Constant Field Values
-
LOG_LEVEL_VERBOSE
public static final int LOG_LEVEL_VERBOSE
Verbose log level- See Also:
- Constant Field Values
-
LOG_LEVEL_DEBUG
public static final int LOG_LEVEL_DEBUG
Debug log level- See Also:
- Constant Field Values
-
LOG_LEVEL_INFO
public static final int LOG_LEVEL_INFO
Info log level- See Also:
- Constant Field Values
-
-
Method Detail
-
checkTag
public static void checkTag(String tag)
-
v
public static void v(String tag, String msg)
Logs a Verbose message.
Will only log this message if log level is set to 3.- Parameters:
tag- String of the tagmsg- String of the message to output
-
v
public static void v(String tag, String msg, Throwable tr)
Logs a Verbose message.
Will only log this message if log level is set to 3.- Parameters:
tag- String of the tagmsg- String of the message to outputtr- the RuntimeException throw object
-
d
public static void d(String tag, String msg)
Logs a Debug message.
Will only log this message if log level is set to 2 or higher.- Parameters:
tag- String of the tagmsg- String of the message to output
-
d
public static void d(String tag, String msg, Throwable tr)
Logs a Debug message.
Will only log this message if log level is set to 2 or higher.- Parameters:
tag- String of the tagmsg- String of the message to outputtr- the RuntimeException throw object
-
i
public static void i(String tag, String msg)
Logs an Info message.
Will only log this message if log level is set to 1 or higher.- Parameters:
tag- String of the tagmsg- String of the message to output
-
i
public static void i(String tag, String msg, Throwable tr)
Logs an Info message.
Will only log this message if log level is set to 1 or higher.- Parameters:
tag- String of the tagmsg- String of the message to outputtr- the RuntimeException throw object
-
w
public static void w(String tag, String msg)
Logs a Warning message.- Parameters:
tag- String of the tagmsg- String of the message to output
-
w
public static void w(String tag, String msg, Throwable tr)
Logs a Warning message.- Parameters:
tag- String of the tagmsg- String of the message to outputtr- the RuntimeException throw object
-
e
public static void e(String tag, String msg)
Logs an Error message.- Parameters:
tag- String of the tagmsg- String of the message to output
-
e
public static void e(String tag, String msg, Throwable tr)
Logs an Error message.- Parameters:
tag- String of the tagmsg- String of the message to outputtr- the RuntimeException throw object
-
always
public static void always(String tag, String msg)
Logs an unblocked Info message.
This message cannot be blocked by setting a log level.- Parameters:
tag- String of the tagmsg- String of the message to output
-
setLogLevel
public static void setLogLevel(int logLevel)
Sets the logging level (threshold).
Valid values:
1 - Info level
2 - Debug level
3 - Verbose level- Parameters:
logLevel- the threshold integer
-
logLevel
public static int logLevel()
Returns the currently set logging level (threshold)- Returns:
- the current threshold log level integer
-
-