Package org.fuin.ddd4j.ddd
Interface Event
-
- All Superinterfaces:
Serializable
- All Known Subinterfaces:
DomainEvent<ID>
- All Known Implementing Classes:
AbstractDomainEvent,AbstractEvent
public interface Event extends Serializable
Something that happened in the system.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description EventIdgetCausationId()Causation identifier.EventIdgetCorrelationId()Correlation identifier.@NotNull EventIdgetEventId()Returns the identifier of the event.@NotNull ZonedDateTimegetEventTimestamp()Date, time and time zone the event was created.@NotNull EventTypegetEventType()Returns the type of the event (What happened).
-
-
-
Method Detail
-
getEventId
@NotNull @NotNull EventId getEventId()
Returns the identifier of the event.- Returns:
- Unique identifier event.
-
getEventType
@NotNull @NotNull EventType getEventType()
Returns the type of the event (What happened).- Returns:
- A text unique for all events of an aggregate.
-
getEventTimestamp
@NotNull @NotNull ZonedDateTime getEventTimestamp()
Date, time and time zone the event was created.- Returns:
- Event creation date and time.
-
getCorrelationId
@Nullable EventId getCorrelationId()
Correlation identifier.- Returns:
- Context of the event.
-
getCausationId
@Nullable EventId getCausationId()
Causation identifier.- Returns:
- Identifier of the evtn that caused this one.
-
-