|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Trace
The Trace
interface defines the methods that allow application tracing.
Trace
also defines the standard trace types as specified by Syslog Trace
Logging.Syslog currently defines 8 levels of trace. The severity of the message is indicated in
the trace as a number ranging between [0-7] (0 and 7 included). Currently 7 is HIGHEST_LEVEL and
0 is the LOWEST_LEVEL trace. All 8 levels are predefined here as static int types for reference
in tracing sub-system implementations.
The severities traced are as follows:
0 = EMERGENCIES System unusable
1 = ALERTS Immediate action needed
2 = CRITICAL Critical conditions
3 = ERROR Error conditions
4 = WARNING Warning conditions
5 = NOTIFICATION Normal but significant condition
6 = INFORMATIONAL Informational messages only
7 = DEBUGGING Debugging messages
Field Summary | |
---|---|
static int |
ALERTS
The application will continue working on the tasks but all functions may not be operational (one or more devices in the list are not accessible but others in the list can be accessed) Syslog severity level = 1 |
static java.lang.String |
ALERTS_TRACE_NAME
String descriptor for ALERTS trace level |
static int |
CRITICAL
A critical failure, the application can not accomplish the tasks required due to this failure, eg: the app can't open the database to read the device list Syslog severity level = 2 |
static java.lang.String |
CRITICAL_TRACE_NAME
String descriptor for CRITICAL trace level |
static int |
DEBUGGING
Very detailed information regarding errors or processing status that is only generated when DEBUG mode has been enabled Syslog severity level = 7 |
static java.lang.String |
DEBUGGING_TRACE_NAME
String descriptor for the DEBUGGING trace level |
static int |
EMERGENCIES
Emergency situation, a system shutdown is necessary Syslog severity level = 0 |
static java.lang.String |
EMERGENCIES_TRACE_NAME
String descriptor for EMERGENCIES trace level |
static int |
ERROR
An error condition of some kind has occurred and the user needs to understand the nature of that failure Syslog severity level = 3 |
static java.lang.String |
ERROR_TRACE_NAME
String descriptor for ERROR trace level |
static int |
HIGHEST_LEVEL
The highest trace level, currently this is DEBUGGING with a trace level of 7 |
static int |
INFORMATIONAL
Information of some form not relating to errors, warnings, audit, or debug Syslog severity level =6 |
static java.lang.String |
INFORMATIONAL_TRACE_NAME
String descriptor for INFORMATIONAL trace level |
static int |
LOWEST_LEVEL
The lowest trace level, currently this is EMERGENCIES with a trace level of 0 |
static int |
NOTIFICATION
Notification denotes a normal but significant condition Syslog severity level = 5 |
static java.lang.String |
NOTIFICATION_TRACE_NAME
String descriptor for NOTIFICATION trace level |
static int |
WARNING
Warning that a problem of some form exists but is not keeping the application from completing its tasks Syslog severity level = 4 |
static java.lang.String |
WARNING_TRACE_NAME
String descriptor for WARNING trace level |
Method Summary | |
---|---|
java.lang.String |
getName()
Returns the name of this Trace object. |
java.lang.String |
getSubFacility()
Returns the subFacility of trace |
int |
getType()
Returns the type of trace. |
boolean |
isEnabled()
Returns the state of this Trace object. |
void |
println(java.lang.Object object)
Prints the string returned by the Object.toString() method and terminates the line as defined by the system. |
void |
println(java.lang.String message)
Prints a message in the same format as Trace.print() and terminates the line as defined by the system. |
void |
println(java.lang.String mnemonic,
java.lang.Object object)
Prints the string returned by the Object.toString() method and terminates the line as defined by the system. |
void |
println(java.lang.String mnemonic,
java.lang.String message)
Prints a message in the same format as Trace.print() and terminates the line as defined by the system. |
void |
setDefaultMnemonic(java.lang.String mnemonic)
Sets a default mnemonic for all messages printed out to this trace. |
Field Detail |
---|
static final int DEBUGGING
static final java.lang.String DEBUGGING_TRACE_NAME
static final int INFORMATIONAL
static final java.lang.String INFORMATIONAL_TRACE_NAME
static final int NOTIFICATION
static final java.lang.String NOTIFICATION_TRACE_NAME
static final int WARNING
static final java.lang.String WARNING_TRACE_NAME
static final int ERROR
static final java.lang.String ERROR_TRACE_NAME
static final int CRITICAL
static final java.lang.String CRITICAL_TRACE_NAME
static final int ALERTS
static final java.lang.String ALERTS_TRACE_NAME
static final int EMERGENCIES
static final java.lang.String EMERGENCIES_TRACE_NAME
static final int LOWEST_LEVEL
static final int HIGHEST_LEVEL
Method Detail |
---|
boolean isEnabled()
ConditionalTrace
void println(java.lang.String mnemonic, java.lang.String message)
message
- the message to be printedmnemonic
- the mnemonic mapped to message to be printedvoid println(java.lang.String message)
message
- the message to be printedvoid println(java.lang.Object object)
object
- the object to be printedvoid println(java.lang.String mnemonic, java.lang.Object object)
object
- the object to be printedmnemonic
- the mnemonic mapped to message to be printedjava.lang.String getName()
void setDefaultMnemonic(java.lang.String mnemonic)
mnemonic
- a mnemonic stringint getType()
java.lang.String getSubFacility()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |