AggregateTypeConfiguration

constructor(aggregateType: AggregateType, aggregateIdType: Class<*>, aggregateIdSerializer: AggregateIdSerializer, deciderSupportsAggregateTypeChecker: DeciderSupportsAggregateTypeChecker, commandAggregateIdResolver: CommandAggregateIdResolver, eventAggregateIdResolver: EventAggregateIdResolver)

Parameters

aggregateType

The AggregateType that is being configured

aggregateIdType

The Aggregate-Id type that is used in commands and events relating to the AggregateType

aggregateIdSerializer

The AggregateIdSerializer capable of serializing/deserializing the AggregateType-Id

deciderSupportsAggregateTypeChecker

A DeciderSupportsAggregateTypeChecker instance which given a concrete Decider instance is capable of determining if the given Decider instance is working with the AggregateType configured in this AggregateTypeConfiguration - see DeciderSupportsAggregateTypeChecker.HandlesCommandsThatInheritsFromCommandType

commandAggregateIdResolver
  • A CommandAggregateIdResolver which can resolve the optional Aggregate-Id value from an instance of a Command compatible with this AggregateType

eventAggregateIdResolver
  • A EventAggregateIdResolver which can resolve the required Aggregate-Id value from an instance of an Event compatible with this AggregateType