public abstract class Event
extends java.lang.Object
implements java.io.Serializable
Event is a abstract class that generalize all events in system.
All event must be extended from Event and have identifier and time point when event created.| Constructor and Description |
|---|
Event()
Create event with random id (UUID) and current time as creation time.
|
Event(java.util.UUID id)
Create event with specified id and current time as creation time.
|
Event(java.util.UUID id,
long timestamp)
Create event with custom id and creation time.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.UUID |
getId()
Returns identifier of event.
|
long |
getTimestamp()
Returns event creation time (timestamp).
|
public Event()
public Event(java.util.UUID id)
id - UUID identifier of event.public Event(java.util.UUID id,
long timestamp)
id - UUID identifier of event.timestamp - timestamp of event creation time in milliseconds.