DeciderCommandHandlerAdapter

class DeciderCommandHandlerAdapter<CMD, EVENT>(decider: Decider<CMD, EVENT>, aggregateTypeConfiguration: AggregateTypeConfiguration, eventStore: EventStore) : CommandHandler

Adapter that allows a Decider to be registered with a dk.cloudcreate.essentials.reactive.command.CommandBus as a CommandHandler

Parameters

decider

the decider instance

aggregateTypeConfiguration

The AggregateTypeConfiguration that matches the dk.cloudcreate.essentials.components.eventsourced.eventstore.postgresql.eventstream.AggregateType that the decider can work with

eventStore

The EventStore that can fetch and persist Events

See also

Constructors

Link copied to clipboard
constructor(decider: Decider<CMD, EVENT>, aggregateTypeConfiguration: AggregateTypeConfiguration, eventStore: EventStore)

Functions

Link copied to clipboard
open override fun canHandle(commandType: Class<*>?): Boolean
Link copied to clipboard
open override fun handle(command: Any): Any?
Link copied to clipboard
open override fun toString(): String