org.olat.core.logging.activity
Interface ILoggingAction
- All Known Implementing Classes:
- BaseLoggingAction, CourseLoggingAction, FolderLoggingAction, GroupLoggingAction, LearningResourceLoggingAction, OlatLoggingAction, StatisticLoggingAction
public interface ILoggingAction
An ILoggingAction is used to summarize all information required to
reflect an occurrance of logging in a particular place in a workflow.
The ILoggingAction therefore contains the following properties, which are
described here shortly:
- resourceAdminAction: specifies the visibility of this logging action
later in the reporting: true for 'only visible to resource admins'
false for 'visible for both resource admins and a normal user'
- crudAction: this is a means to allow simplified SQL statements on the logging
table later by specifying - at log-runtime-time - whether this logging action
is about retrieving something, updating, deleting or creating.
Not always can an action easily be associated to one of them - in which case
it is best to default back to retrieve
- logMessage: the actual log message. Please follow the standard way of composing
a log message - which is something like LEARNING_RESOURCE_OPEN
- typeListDefinition: this is an instance of ResourceableTypeList which defines
what ILoggingResourceableTypes are expected and allowed to be stored to the
DB along side this log message. It also serves as a way to document
possible occurrances
Furthermore there is a property called javaFieldIdForDebug - which is only used for
debugging (as the name suggests). In the default implementation (LoggingAction)
it is set to the actual java filed name - allowing quicker debugging.
Initial Date: 20.10.2009
- Author:
- Stefan
|
Method Summary |
java.lang.String |
getActionObject()
Returns the actionObject of this logging action. |
ActionVerb |
getActionVerb()
Returns the actionVerb of this logging action. |
CrudAction |
getCrudAction()
Returns the type of action this logging action represents -
which is one of Create, Retrieve, Update or Delete. |
java.lang.String |
getJavaFieldIdForDebug()
This is for DEBUG only - it is usually mapped to the
name of the static field and issued in technical logging
when the ResourceableType-Check fails |
ActionType |
getResourceActionType()
Returns whether this logging action is only visible to a resource admin
(true) or also to a user (false) |
ResourceableTypeList |
getTypeListDefinition()
Returns the ResourceableTypeList - which is a list
of ILoggingResourceableTypes defining what is expected
to be stored to the DB alongside this logging action |
getResourceActionType
ActionType getResourceActionType()
- Returns whether this logging action is only visible to a resource admin
(true) or also to a user (false)
- Returns:
- whether this logging action is only for the eyes of
a resource admin (true) or also for users (false)
getCrudAction
CrudAction getCrudAction()
- Returns the type of action this logging action represents -
which is one of Create, Retrieve, Update or Delete.
- Returns:
- the crudAction of this logging action
getActionVerb
ActionVerb getActionVerb()
- Returns the actionVerb of this logging action.
- Returns:
- the actionVerb of this logging action
getActionObject
java.lang.String getActionObject()
- Returns the actionObject of this logging action.
Note that this is not an enum like ActionVerb
since it is distributed amongst the ILoggingAction
implementors - who themselves are very encouraged
to use an enum underneath though and use name() on
that!
- Returns:
- the actionObject of this logging action
getTypeListDefinition
ResourceableTypeList getTypeListDefinition()
- Returns the ResourceableTypeList - which is a list
of ILoggingResourceableTypes defining what is expected
to be stored to the DB alongside this logging action
- Returns:
- the ResourceableTypeList which defines what
is expected to be stored alongside this logging action
getJavaFieldIdForDebug
java.lang.String getJavaFieldIdForDebug()
- This is for DEBUG only - it is usually mapped to the
name of the static field and issued in technical logging
when the ResourceableType-Check fails
- Returns:
- the name of the (static) java filed which holds
this logging action - for DEBUG only, so don't worry