[TYPO3-mvc] Cloning properties in setter and getter methods of models (blog example)
Thomas "Thasmo" Deinhamer
thasmo at gmail.com
Fri Feb 11 19:06:46 CET 2011
Franz Koch wrote:
> So one can't simply fetch all Tags and add a new one to this
> objectStorage which would be out of the scope of the domain models
> responsibility (because maybe the setter from the domain model is
> triggering some additional methods that depend on the setter etc).
Hello Franz!
That's a good point. So is there any recommendation what to use
in general? Would it be "wrong" to not clone the objects?
Probably it would be the best way to clone objects everytime
in all getters and setters to ensure all is working properly, right?
Thanks for feedback,
Thomas
More information about the TYPO3-project-typo3v4mvc
mailing list