|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.xbus.base.core.trace.Trace
public class Trace
Trace
writes program-internal informations to a sink. The most
important use of Trace
is writing informations, when an error
occurs, e.g. the queue-server is not available.
Field Summary | |
---|---|
static int |
ALWAYS
|
static int |
DEBUG
|
static int |
ERROR
|
static int |
INFO
|
static int |
WARN
|
Constructor Summary | |
---|---|
Trace()
|
Method Summary | |
---|---|
static void |
always(java.lang.Object message)
Traces a message object with the ALWAYS priority. |
static void |
error(java.lang.Object message)
Traces a message object with the ERROR priority. |
static void |
error(java.lang.Object message,
java.lang.Throwable t)
Traces a message object with the ERROR priority including the stack trace of the Throwable t passed as parameter. |
static void |
error(java.lang.Throwable t)
Traces a message object with the ERROR priority including the message and the stack trace of the Throwable t passed as parameter. |
static java.lang.String |
getTrace()
Returns all trace messages as one large string. |
static int |
getTracelevel()
|
static void |
info(java.lang.Object message)
Traces a message object with the INFO priority. |
static void |
initialize()
The initialize() method reads the name and the level of
the trace from the Configuration and initializes the
Tracing |
static boolean |
isInitialized()
Tests if the Tracer is initialized. |
static void |
warn(java.lang.Object message)
Traces a message object with the WARN priority. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int DEBUG
public static final int INFO
public static final int WARN
public static final int ERROR
public static final int ALWAYS
Constructor Detail |
---|
public Trace()
Method Detail |
---|
public static void always(java.lang.Object message)
message
- the message to be tracedpublic static void error(java.lang.Object message)
message
- the message to be tracedpublic static void error(java.lang.Throwable t)
When the Throwable
is an XException
nothing
happens, because the XException
has been traced before.
t
- the Throwable which shall be traced.public static void error(java.lang.Object message, java.lang.Throwable t)
message
- the message to be tracedt
- the stack trace of the Throwablepublic static void warn(java.lang.Object message)
message
- the message to be tracedpublic static void info(java.lang.Object message)
message
- the message to be tracedpublic static void initialize()
initialize()
method reads the name and the level of
the trace from the Configuration
and initializes the
Tracing
Configuration.getValue(String,String,String)
public static java.lang.String getTrace()
public static boolean isInitialized()
public static int getTracelevel()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |