Re: Value object with set of aggregate roots?

"Hugo van Elk [email protected] [domaindrivendesign]" <[email protected]> Thu, 11 Jun 2015 22:57:47 +0200
Newsgroups gmane.comp.programming.domain-driven-design
Message-ID <CAHP7VZmfpeQuT20bdJeRCDh=T4g5rwWZhN-0zQb2iRdd8hFCjA@mail.gmail.com>
I would go for the value object picture. This because it is input for the
calculation. Otherwise, the outcome of the calculation cannot be related to
a defined input.


BTW, in (pure) functional programming, all variables are immutable. This
fits nicely into a more mathematical domain. In mathematics, the variables
do not change either during the calculation ;-)


The Picture itself is of course mutable. But maybe you need the notion of a
snapshot of the picture? That is: the Picture instance as value object
together with a timstamp? You can provide this tuple as input for the
calculation.


Just an idea and some free associations. I'm looking forward to the
reactions of others.