Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AggregateStore ¶
type AggregateStore interface { Load(aggregateID cqrs.Identifier, aggregateType string) (cqrs.ESAggregate, error) Store(aggregate cqrs.ESAggregate, events ...cqrs.DomainEvent) error }
AggregateStore loads and stores the aggregate.
type EventHandler ¶
type EventHandler interface { SubscribedTo() cqrs.EventMatcher Handle(cqrs.DomainEvent) error }
EventHandler handles events that were published though EventPublisher.
type EventHandlerFunc ¶
type EventHandlerFunc func(cqrs.DomainEvent) error
EventHandlerFunc is a function that can be used as an event handler.
type EventPublisher ¶
type EventPublisher interface {
Publish(e ...cqrs.DomainEvent) error
}
EventPublisher publishes events.
type EventStore ¶
type EventStore interface { LoadEventsFor(aggregateID cqrs.Identifier) ([]cqrs.DomainEvent, error) StoreEventsFor(aggregateID cqrs.Identifier, version int, events []cqrs.DomainEvent) error }
EventStore stores and loads events.
Click to show internal directories.
Click to hide internal directories.