Class AggregateSnapshot<ID,AGGREGATE_IMPL_TYPE>
- java.lang.Object
-
- dk.cloudcreate.essentials.components.eventsourced.aggregates.snapshot.AggregateSnapshot<ID,AGGREGATE_IMPL_TYPE>
-
- Type Parameters:
ID- the aggregate ID typeAGGREGATE_IMPL_TYPE- the concrete aggregate implementation type
public class AggregateSnapshot<ID,AGGREGATE_IMPL_TYPE> extends Object
Aggregate snapshot loaded usingAggregateSnapshotRepository.loadSnapshot(AggregateType, Object, Class)
-
-
Field Summary
Fields Modifier and Type Field Description IDaggregateIdthe identifier for the aggregate instanceClass<AGGREGATE_IMPL_TYPE>aggregateImplTypethe concrete aggregate implementation typeAGGREGATE_IMPL_TYPEaggregateSnapshotThe aggregate snapshot loaded from the repository - if this is of typeBrokenSnapshotthen the Aggregate snapshot couldn't be deserializeddk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.eventstream.AggregateTypeaggregateTypethe name of the aggregate's event streamdk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.types.EventOrdereventOrderOfLastIncludedEventTheEventOrderof the last Event that was included in the snapshot
-
Constructor Summary
Constructors Constructor Description AggregateSnapshot(dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.eventstream.AggregateType aggregateType, ID aggregateId, Class<AGGREGATE_IMPL_TYPE> aggregateImplType, AGGREGATE_IMPL_TYPE aggregateSnapshot, dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.types.EventOrder eventOrderOfLastIncludedEvent)
-
-
-
Field Detail
-
aggregateType
public final dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.eventstream.AggregateType aggregateType
the name of the aggregate's event stream
-
aggregateId
public final ID aggregateId
the identifier for the aggregate instance
-
aggregateImplType
public final Class<AGGREGATE_IMPL_TYPE> aggregateImplType
the concrete aggregate implementation type
-
eventOrderOfLastIncludedEvent
public final dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.types.EventOrder eventOrderOfLastIncludedEvent
TheEventOrderof the last Event that was included in the snapshot
-
aggregateSnapshot
public final AGGREGATE_IMPL_TYPE aggregateSnapshot
The aggregate snapshot loaded from the repository - if this is of typeBrokenSnapshotthen the Aggregate snapshot couldn't be deserialized
-
-
Constructor Detail
-
AggregateSnapshot
public AggregateSnapshot(dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.eventstream.AggregateType aggregateType, ID aggregateId, Class<AGGREGATE_IMPL_TYPE> aggregateImplType, AGGREGATE_IMPL_TYPE aggregateSnapshot, dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.types.EventOrder eventOrderOfLastIncludedEvent)- Parameters:
aggregateType- the name of the aggregate's event streamaggregateId- the identifier for the aggregate instanceaggregateImplType- the concrete aggregate implementation typeaggregateSnapshot- The aggregate snapshot loaded from the repository (optional as we can load snapshots without payload)eventOrderOfLastIncludedEvent- TheEventOrderof the last Event that was included in the snapshot
-
-