Class CollectionEventInfo<T>
java.lang.Object
org.dizitart.no2.collection.events.CollectionEventInfo<T>
Represents a collection event data.
- Since:
- 4.0
- Author:
- Anindya Chatterjee
-
Constructor Summary
ConstructorsConstructorDescriptionCollectionEventInfo(EventType eventType) CollectionEventInfo(T item, EventType eventType, long timestamp, String originator) Creates a newCollectionEventInfoinstance. -
Method Summary
Modifier and TypeMethodDescriptionbooleanSpecifies the event type.getItem()Specifies the item triggering the event.Specifies the name of the originator who has initiated this event.longSpecifies the unix timestamp of the change.inthashCode()voidsetEventType(EventType eventType) Specifies the event type.voidSpecifies the item triggering the event.voidsetOriginator(String originator) Specifies the name of the originator who has initiated this event.voidsetTimestamp(long timestamp) Specifies the unix timestamp of the change.toString()
-
Constructor Details
-
CollectionEventInfo
-
CollectionEventInfo
public CollectionEventInfo() -
CollectionEventInfo
Creates a newCollectionEventInfoinstance.- Parameters:
item- the item that changed.eventType- the type of the event.timestamp- the unix timestamp of the change.originator- name of originator of the event.
-
-
Method Details
-
getItem
Specifies the item triggering the event.- Returns:
- the item.
-
getEventType
Specifies the event type.- Returns:
- the type of the event.
-
getTimestamp
public long getTimestamp()Specifies the unix timestamp of the change.- Returns:
- the unix timestamp of the change.
-
getOriginator
Specifies the name of the originator who has initiated this event.- Returns:
- name of the originator.
- Since:
- 4.0
-
setItem
Specifies the item triggering the event.- Parameters:
item- the item that changed.
-
setEventType
Specifies the event type.- Parameters:
eventType- the type of the event.
-
setTimestamp
public void setTimestamp(long timestamp) Specifies the unix timestamp of the change.- Parameters:
timestamp- the unix timestamp of the change.
-
setOriginator
Specifies the name of the originator who has initiated this event.- Parameters:
originator- name of originator of the event.- Since:
- 4.0
-
equals
-
hashCode
public int hashCode() -
toString
-