public final static String DEBUG = "DEBUG";\r
public final static String TRACE = "TRACE";\r
\r
- /** @deprecated*/\r
+ /** @deprecated */\r
public final static String START = "START";\r
- /** @deprecated*/\r
+ /** @deprecated */\r
public final static String END = "END";\r
\r
// TODO make the fields final and private when we don't need POJO support\r
protected Date timestamp;\r
protected String log;\r
\r
+ private String location;\r
+\r
/** Empty constructor */\r
public ExecutionStep() {\r
- thread = Thread.currentThread().getName();\r
- }\r
-\r
- /** Creates a step at the current date of type INFO */\r
- public ExecutionStep(String log) {\r
- this(new Date(), INFO, log);\r
+ Thread currentThread = Thread.currentThread();\r
+ thread = currentThread.getName();\r
}\r
\r
/** Creates a step at the current date */\r
- public ExecutionStep(String type, String log) {\r
- this(new Date(), type, log);\r
+ public ExecutionStep(String location, String type, String log) {\r
+ this(location, new Date(), type, log);\r
}\r
\r
/** Creates a step of the given type. */\r
- public ExecutionStep(Date timestamp, String type, String log) {\r
- this(timestamp, type, log, Thread.currentThread().getName());\r
+ public ExecutionStep(String location, Date timestamp, String type,\r
+ String log) {\r
+ this(location, timestamp, type, log, Thread.currentThread().getName());\r
}\r
\r
- public ExecutionStep(Date timestamp, String type, String log, String thread) {\r
+ public ExecutionStep(String location, Date timestamp, String type,\r
+ String log, String thread) {\r
+ this.location = location;\r
this.type = type;\r
this.timestamp = timestamp;\r
this.thread = thread;\r
return "Execution step, thread=" + thread + ", type=" + type;\r
}\r
\r
+ /** Typically the logging category */\r
+ public String getLocation() {\r
+ return location;\r
+ }\r
+\r
}\r