Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Aggregate ¶
type Aggregate interface { // 初始化聚合 Init(state AggregateState) // 当前聚合操作产生的变化,以一组事件来表示 Changes() []Event // 将聚合操作创建的事件进行应用:更改聚合状态、记录到Changes中 Apply(e Event) }
聚合
type AggregateIdentity ¶
聚合标识
type AggregateState ¶
type AggregateState interface { // 初始化聚合状态 Init(events []Event) // 聚合状态版本 Version() int // 通过事件改变聚合状态 Mutate(e Event) }
聚合状态
type EventPublisher ¶
type EventPublisher interface { }
type EventStream ¶
事件流
Click to show internal directories.
Click to hide internal directories.