Raptor Aggregate Definition
data class RaptorAggregateDefinition<Aggregate : RaptorAggregate<Id, Command, Change>, Id : RaptorAggregateId, Command : RaptorAggregateCommand<Id>, Change : RaptorAggregateChange<Id>>(val aggregateClass: KClass<Aggregate>, val changeClass: KClass<Change>, val changeDefinitions: Set<RaptorAggregateChangeDefinition<Id, out Change>>, val commandClass: KClass<Command>, val commandDefinitions: Set<RaptorAggregateCommandDefinition<Id, out Command>>, val discriminator: String, val factory: RaptorAggregateFactory<Aggregate, Id>, val idClass: KClass<Id>, val projectionDefinition: RaptorAggregateProjectionDefinition<*, *, Change>? = null)
Constructors
Link copied to clipboard
fun <Aggregate : RaptorAggregate<Id, Command, Change>, Id : RaptorAggregateId, Command : RaptorAggregateCommand<Id>, Change : RaptorAggregateChange<Id>> RaptorAggregateDefinition(aggregateClass: KClass<Aggregate>, changeClass: KClass<Change>, changeDefinitions: Set<RaptorAggregateChangeDefinition<Id, out Change>>, commandClass: KClass<Command>, commandDefinitions: Set<RaptorAggregateCommandDefinition<Id, out Command>>, discriminator: String, factory: RaptorAggregateFactory<Aggregate, Id>, idClass: KClass<Id>, projectionDefinition: RaptorAggregateProjectionDefinition<*, *, Change>? = null)
Functions
Link copied to clipboard
fun castOrNull(event: RaptorAggregateEvent<Id, RaptorAggregateChange<Id>>): RaptorAggregateEvent<Id, Change>?
Link copied to clipboard
fun <TEvent : RaptorAggregateChange<Id>> changeDefinition(changeClass: KClass<out TEvent>): RaptorAggregateChangeDefinition<Id, out Change>?
Link copied to clipboard
fun <TCommand : RaptorAggregateCommand<Id>> commandDefinition(commandClass: KClass<out TCommand>): RaptorAggregateCommandDefinition<Id, out Command>?