File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed
Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -41,12 +41,14 @@ construct a snapshot object from an aggregate object.
4141Domain model
4242------------
4343
44- The :class: `~examples.aggregate5.domainmodel.Dog ` aggregate is defined as immutable frozen data class that extends
45- the aggregate base class. Event classes are explicitly defined and explicitly triggered in command methods.
46-
47- It defines a :func: `~examples.aggregate5.domainmodel.Dog.mutate ` method, which
48- evolves aggregate state by constructing a new instance of the aggregate class each time it is called,
49- according to the type of event it is called with.
44+ The :class: `~examples.aggregate5.domainmodel.Dog ` aggregate class is defined as immutable frozen data class
45+ that extends the aggregate base class. The aggregate event classes, :class: `~examples.aggregate5.domainmodel.Dog.Registered ` and
46+ :class: `~examples.aggregate5.domainmodel.Dog.TrickAdded `, are explicitly defined.
47+
48+ The :class: `~examples.aggregate5.domainmodel.Dog ` aggregate class defines a
49+ :func: `~examples.aggregate5.domainmodel.Dog.mutate ` method, which evolves aggregate state by constructing a new
50+ instance of the aggregate class each time it is called, according to the type of event it is called with. Support
51+ for reconstructing an aggregate object from an aggregate snapshot object is included in this method.
5052
5153.. literalinclude :: ../../../examples/aggregate5/domainmodel.py
5254 :pyobject: Dog
You can’t perform that action at this time.
0 commit comments