public class Event extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
EVENT_BEAN_PREFIX |
static String |
EVENT_ID_START |
static String |
EVENT_NAME_START |
static String |
FIELD_DATA |
static String |
FIELD_DATA_OWNER |
static String |
FIELD_DRIVER |
static String |
FIELD_ID |
static String |
FIELD_LOCK_OWNER |
static String |
FIELD_LOCK_TIME |
static String |
FIELD_NAME |
static String |
FIELD_SCHEDULED_TIME |
static String |
FIELD_SESSION_ID |
static String |
FIELD_VALUE
The 'value' that is associated with the data
|
| Constructor and Description |
|---|
Event(String name,
long scheduledTime,
Object data)
Construct a scheduled event with some data.
|
Event(String name,
long scheduledTime,
Object data,
boolean dataInMemory)
Construct a scheduled event with some data, optionally forcing the data to be stored
in memory.
|
Event(String name,
Object data)
Construct an event with some data, scheduling it for the current time.
|
| Modifier and Type | Method and Description |
|---|---|
static boolean |
canPersistDataObject(Object data)
Determine if the data can be written out to MongoDB
|
boolean |
equals(Object obj) |
Object |
getData() |
boolean |
getDataInMemory() |
Object |
getDataObject()
Deprecated.
in V2.0.2
|
String |
getDriver() |
String |
getId() |
String |
getLockOwner() |
long |
getLockTime() |
String |
getName() |
long |
getScheduledTime() |
String |
getSessionId() |
int |
hashCode() |
void |
setDriver(String driver) |
void |
setId(String id) |
void |
setLockOwner(String lockOwner) |
void |
setLockTime(long lockTime) |
void |
setSessionId(String sessionId) |
String |
toString() |
public static final String FIELD_ID
public static final String FIELD_NAME
public static final String FIELD_SESSION_ID
public static final String FIELD_SCHEDULED_TIME
public static final String FIELD_LOCK_OWNER
public static final String FIELD_LOCK_TIME
public static final String FIELD_DATA
public static final String FIELD_DATA_OWNER
public static final String FIELD_DRIVER
public static final String FIELD_VALUE
public static final String EVENT_NAME_START
public static final String EVENT_ID_START
public static final String EVENT_BEAN_PREFIX
public Event(String name, Object data)
DBObject to allow full MongoDB-friendly persistence, allowing
searching for data.X-style searches where the object has key *X*, say.
The data, if a String, will be persisted directly with this event.name - the event namedata - the event datapublic Event(String name, long scheduledTime, Object data)
DBObject to allow full MongoDB-friendly persistence, allowing
searching for data.X-style searches where the object has key *X*, say.
The data, if a String, will be persisted directly with this event.
Events that keep their data in memory cannot be executed by any other
running service and will therefore be lost if the server goes down.name - the event namescheduledTime - when the event should be processeddata - the event datapublic Event(String name, long scheduledTime, Object data, boolean dataInMemory)
String, then the data will be stored in local memory and a unique
look-up key will be persisted.
Use a DBObject to allow full MongoDB-friendly persistence, allowing
searching for data.X-style searches where the object has key *X*, say.
The data, if a String, will be persisted directly with this event.
Events that keep their data in memory cannot be executed by any other
running service and will therefore be lost if the server goes down.name - the event namescheduledTime - when the event should be processeddata - the event datadataInMemory - prevent the data from being persisted to the event storage.
Incompatible data types will be handled automatically,
but there may be cases where sensitive data may need to be kept
in memory for some reason.public static boolean canPersistDataObject(Object data)
data - the data to store (in memory or persisted)public String getId()
public void setId(String id)
public String getName()
public String getSessionId()
public void setSessionId(String sessionId)
public long getScheduledTime()
public String getLockOwner()
public void setLockOwner(String lockOwner)
public long getLockTime()
public void setLockTime(long lockTime)
public Object getData()
public boolean getDataInMemory()
@Deprecated public Object getDataObject()
public String getDriver()
public void setDriver(String driver)
Copyright © 2005–2018 Alfresco Software. All rights reserved.