java.lang.Object
io.ebean.event.readaudit.ReadEvent
Read event sent to the ReadEventLogger.
This is a flattened in that it contains either a read bean or list of beans. It is flattened in this way to simplify logging and processing and simply means that it either contains an id or a list of ids.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected StringThe type of the bean(s) read.protected StringThe bind log when the query was executed.protected longThe time the bean change was created.protected ObjectThe id of the bean read.The ids of the beans read.protected StringThe query key (relative to the bean type).protected StringUser defined 'source' such as the application name.Arbitrary user context information expected to be optionally populated by ChangeLogPrepare.protected StringApplication user id expected to be optionally populated by ChangeLogPrepare.protected StringApplication user ip address expected to be optionally populated by ChangeLogPrepare. -
Constructor Summary
ConstructorsModifierConstructorDescriptionConstructor for JSON tools.Construct for many future list query.protectedCommon constructor for single bean and multi-bean read events.Construct for a single bean read.Construct for many beans read. -
Method Summary
Modifier and TypeMethodDescriptionReturn the type of bean read.Return the bind log used when executing the query.longReturn the event date time.getId()Return the id of the bean read.getIds()Return the ids of the beans read.Return the query key (relative to the bean type).Return a code that identifies the source of the change (like the name of the application).Return a user context value - anything you set yourself in ChangeLogListener prepare().Return the application user Id.Return the application users ip address.voidsetBeanType(String beanType) Set the type of bean read.voidsetBindLog(String bindLog) Set the bind log used when executing the query.voidsetEventTime(long eventTime) Set the event date time.voidSet the id of the bean read.voidSet the ids of the beans read.voidsetQueryKey(String queryKey) Set the query key (relative to the bean type).voidSet the source of the change (like the name of the application).voidsetUserContext(Map<String, String> userContext) Set a user context value (anything you like).voidSet the application user Id.voidsetUserIpAddress(String userIpAddress) Set the application users ip address.
-
Field Details
-
source
User defined 'source' such as the application name. -
userId
Application user id expected to be optionally populated by ChangeLogPrepare. -
userIpAddress
Application user ip address expected to be optionally populated by ChangeLogPrepare. -
userContext
Arbitrary user context information expected to be optionally populated by ChangeLogPrepare. -
eventTime
protected long eventTimeThe time the bean change was created. -
beanType
The type of the bean(s) read. -
queryKey
The query key (relative to the bean type). -
bindLog
The bind log when the query was executed. -
id
The id of the bean read. -
ids
The ids of the beans read.
-
-
Constructor Details
-
ReadEvent
Common constructor for single bean and multi-bean read events. -
ReadEvent
Construct for a single bean read. -
ReadEvent
Construct for many beans read. -
ReadEvent
Construct for many future list query. -
ReadEvent
public ReadEvent()Constructor for JSON tools.
-
-
Method Details
-
getSource
Return a code that identifies the source of the change (like the name of the application). -
setSource
Set the source of the change (like the name of the application). -
getUserId
Return the application user Id. -
setUserId
Set the application user Id.This can be set by the ChangeLogListener in the prepare() method which is called in the foreground thread.
-
getUserIpAddress
Return the application users ip address. -
setUserIpAddress
Set the application users ip address.This can be set by the ChangeLogListener in the prepare() method which is called in the foreground thread.
-
getUserContext
Return a user context value - anything you set yourself in ChangeLogListener prepare(). -
setUserContext
Set a user context value (anything you like).This can be set by the ChangeLogListener in the prepare() method which is called in the foreground thread.
-
getBeanType
Return the type of bean read. -
setBeanType
Set the type of bean read. -
getQueryKey
Return the query key (relative to the bean type). -
setQueryKey
Set the query key (relative to the bean type). -
getBindLog
Return the bind log used when executing the query. -
setBindLog
Set the bind log used when executing the query. -
getEventTime
public long getEventTime()Return the event date time. -
setEventTime
public void setEventTime(long eventTime) Set the event date time. -
getId
Return the id of the bean read. -
setId
Set the id of the bean read. -
getIds
Return the ids of the beans read. -
setIds
Set the ids of the beans read.
-