Package com.jalios.jcms.analytics
Class EventData
java.lang.Object
com.jalios.jcms.analytics.EventData
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
UsageEventData
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionEventData(String type, Member actor, String action, Data data, javax.servlet.http.HttpServletRequest request) EventData(String type, Member actor, String action, Data data, javax.servlet.http.HttpServletRequest request, long eventDate) EventData(String type, Member actor, String action, Data data, javax.servlet.http.HttpServletRequest request, long startDate, long endDate, long eventDate) EventData(String type, Member actor, String action, String dataId, String dataClass, long eventDate, String urid, long startDate, long endDate) Create eventData for some core action (like CSRF error, RSS access, OpenAPI access, AuthFail, ...) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddContext(Map<String, String> tmpContext) getActor()getData()longgetDate()longCompute real class from object class stringlonggetType()getUrid()booleanisAccess()Indicates if this event has the typeAnalyticsManager.ACCESSbooleanisCore()Indicates if this event has the typeAnalyticsManager.COREbooleanisCreate()returns true if the eventData is a creation event (op is Create and DeepCopy), false otherwisebooleanisDelete()returns true if the eventData is a delete event (op is Delete and DeepDelete), false otherwisebooleanisInstanceOf(Class clazz) returns true if theEventDatais about the provided classbooleanIndicates if this event has the typeAnalyticsManager.OPENAPIbooleanIndicates if this event has the provided typebooleanisUpdate()returns true if the eventData is a update event (op is Update and Merge), false otherwisebooleanisUsage()Indicates if this event has the typeAnalyticsManager.USAGEvoidvoidvoidsetContext(Map<String, String> context) voidvoidsetDate(long date) voidsetEndDate(long endDate) voidsetObjectClass(String objectClass) voidsetObjectId(String objectId) voidsetStartDate(long startDate) voidvoidtoString()
-
Constructor Details
-
EventData
public EventData() -
EventData
-
EventData
-
EventData
-
EventData
-
EventData
-
EventData
Create eventData for some core action (like CSRF error, RSS access, OpenAPI access, AuthFail, ...)- Parameters:
type- the type of theEventData(oftenAnalyticsManager.CORE)action- the action of theEventData(likeAnalyticsManager.CSRF_ERRORorAnalyticsManager.AUTH_FAIL)
-
-
Method Details
-
setData
-
getData
-
getType
- Returns:
- the type
-
setType
- Parameters:
type- the type to set
-
getActor
- Returns:
- the actor
-
setActor
- Parameters:
actor- the actor to set
-
getAction
- Returns:
- the action
-
setAction
- Parameters:
action- the action to set
-
getObjectId
- Returns:
- the objectId
-
setObjectId
- Parameters:
objectId- the objectId to set
-
getObjectClass
- Returns:
- the objectClass
-
setObjectClass
- Parameters:
objectClass- the objectClass to set
-
getContext
- Returns:
- the context
-
setContext
- Parameters:
context- the context to set
-
getDate
public long getDate()- Returns:
- the date
-
setDate
public void setDate(long date) - Parameters:
date- the date to set
-
getStartDate
public long getStartDate()- Returns:
- the startDate
-
setStartDate
public void setStartDate(long startDate) - Parameters:
startDate- the startDate to set
-
getEndDate
public long getEndDate()- Returns:
- the endDate
-
setEndDate
public void setEndDate(long endDate) - Parameters:
endDate- the endDate to set
-
getUrid
- Returns:
- the urid
-
setUrid
- Parameters:
urid- the urid to set
-
addContext
-
toString
-
isType
Indicates if this event has the provided type- Parameters:
type- the type to check- Returns:
- true if the event type is the same than the parameter
-
isCore
public boolean isCore()Indicates if this event has the typeAnalyticsManager.CORE- Returns:
- true if the event type is
AnalyticsManager.CORE
-
isAccess
public boolean isAccess()Indicates if this event has the typeAnalyticsManager.ACCESS- Returns:
- true if the event type is
AnalyticsManager.ACCESS
-
isUsage
public boolean isUsage()Indicates if this event has the typeAnalyticsManager.USAGE- Returns:
- true if the event type is
AnalyticsManager.USAGE
-
isOpenApi
public boolean isOpenApi()Indicates if this event has the typeAnalyticsManager.OPENAPI- Returns:
- true if the event type is
AnalyticsManager.OPENAPI
-
isCreate
public boolean isCreate()returns true if the eventData is a creation event (op is Create and DeepCopy), false otherwise- Returns:
- true if the eventData is a creation event (op is Create and DeepCopy), false otherwise
-
isDelete
public boolean isDelete()returns true if the eventData is a delete event (op is Delete and DeepDelete), false otherwise- Returns:
- true if the eventData is a delete event (op is Delete and DeepDelete), false otherwise
-
isUpdate
public boolean isUpdate()returns true if the eventData is a update event (op is Update and Merge), false otherwise- Returns:
- true if the eventData is a update event (op is Update and Merge), false otherwise
-
isInstanceOf
returns true if theEventDatais about the provided class -
getRealObjectClass
Compute real class from object class string- Returns:
- the computed class, or null if objectClass does not exist
-