|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.kwfgrid.gwes.GWESLogger
public abstract class GWESLogger
This is an abstract class for logging all user access to the GWES engine, workflows and activities. You may develop your own implementation of this class, regarding your logging requirements. The default implementation is net.kwfgrid.gwes.GWESBasicLogger. Use property "gwes.logger.class" in gwes.properties to configure the implementation of the GWESLogger.
| Nested Class Summary | |
|---|---|
static class |
GWESLogger.Event
Type of event. |
static class |
GWESLogger.EventOutcome
Outcome of the event. |
static class |
GWESLogger.Level
Level of logging. |
| Constructor Summary | |
|---|---|
protected |
GWESLogger()
Only for internal usage, use getInstance() to get instance of GWESLogger. |
| Method Summary | |
|---|---|
boolean |
e()
ERROR enabled |
boolean |
f()
FATAL enabled |
String |
getGwesId()
|
static GWESLogger |
getInstance()
Get instance of GWESLogger implementation. |
GWESLogger.Level |
getLevel()
Get the logger level. |
boolean |
i()
INFO enabled |
void |
logEvent(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
String[] paramNames,
String[] oldValues,
String[] newValues,
Throwable exception)
Log an event. |
void |
logEvent(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
Throwable exception)
Log an event without parameter. |
void |
logEvent(GWESLogger.Event event,
String userID,
Object object)
Log an successful event with EventOutcome.SUCCESS without parameter. |
void |
logEvent(GWESLogger.Event event,
String userID,
Object object,
String[] paramNames,
String[] oldValues,
String[] newValues)
Log an successful event with EventOutcome.SUCCESS and multiple parameters. |
protected abstract void |
logEventLevelChecked(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
String[] paramNames,
String[] oldValues,
String[] newValues,
Throwable exception)
Log an event. |
void |
logEventSP(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
String paramName,
String oldValue,
String newValue,
Throwable exception)
Log an event with single parameter. |
void |
logEventSP(GWESLogger.Event event,
String userID,
Object object,
String paramName,
String oldValue,
String newValue)
Log an successful event with EventOutcome.SUCCESS and with single parameter. |
boolean |
q()
QUIET enabled |
void |
setLevel(GWESLogger.Level level,
String userID)
Set the logger level. |
boolean |
w()
WARN enabled |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected GWESLogger()
| Method Detail |
|---|
public static GWESLogger getInstance()
throws LoggingException
LoggingException - If it was not possible to create a GWESLogger instance.public GWESLogger.Level getLevel()
public boolean i()
public boolean w()
public boolean e()
public boolean f()
public boolean q()
public void setLevel(GWESLogger.Level level,
String userID)
throws LoggingException
level - The new logger level.userID - The user ID of the user, who is responsible for invoking this method.
LoggingExceptionpublic String getGwesId()
public void logEventSP(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
String paramName,
String oldValue,
String newValue,
Throwable exception)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.eventOutcome - The event outcome, refer to GWESLogger.EventOutcome.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.paramName - The parameter names.oldValue - The old value of the parameter.newValue - The new value of the parameter.exception - The exception if event outcome was not GWES.Logger.EventOutcome.SUCCESS, or null if not available.
LoggingException - If logging fails.
public void logEvent(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
Throwable exception)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.eventOutcome - The event outcome, refer to GWESLogger.EventOutcome.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.exception - The exception if event outcome was not GWES.Logger.EventOutcome.SUCCESS, or null if not available.
LoggingException - If logging fails.
public void logEvent(GWESLogger.Event event,
String userID,
Object object,
String[] paramNames,
String[] oldValues,
String[] newValues)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.paramNames - A String array of parameter names.oldValues - A String array of the old values of the parameters.newValues - A String array of the new values of the parameters.
LoggingException - If logging fails.
public void logEventSP(GWESLogger.Event event,
String userID,
Object object,
String paramName,
String oldValue,
String newValue)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.paramName - The parameter names.oldValue - The old value of the parameter.newValue - The new value of the parameter.
LoggingException - If logging fails.
public void logEvent(GWESLogger.Event event,
String userID,
Object object)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.
LoggingException - If logging fails.
public void logEvent(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
String[] paramNames,
String[] oldValues,
String[] newValues,
Throwable exception)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.eventOutcome - The event outcome, refer to GWESLogger.EventOutcome.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.paramNames - A String array of parameter names.oldValues - A String array of the old values of the parameters.newValues - A String array of the new values of the parameters.exception - The exception if event outcome was not GWES.Logger.EventOutcome.SUCCESS, or null if not available.
LoggingException - If logging fails.
protected abstract void logEventLevelChecked(GWESLogger.Event event,
GWESLogger.EventOutcome eventOutcome,
String userID,
Object object,
String[] paramNames,
String[] oldValues,
String[] newValues,
Throwable exception)
throws LoggingException
event - The type of event, refer to GWESLogger.Event.eventOutcome - The event outcome, refer to GWESLogger.EventOutcome.userID - The user ID of the user who triggered this event, or null if not available.object - The object which is related to the event, e.g. the Workflow or Activity instance, or null if not available.paramNames - A String array of parameter names.oldValues - A String array of the old values of the parameters.newValues - A String array of the new values of the parameters.exception - The exception if event outcome was not GWES.Logger.EventOutcome.SUCCESS, or null if not available.
LoggingException - If logging fails.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||