[TYPO3-dev] SOLUTION (?) : Multiple XCLASS inheritance
Michael Scharkow
mscharkow at gmx.net
Wed Feb 8 19:17:18 CET 2006
Kasper Skårhøj wrote:
> Also, inheritance as a whole should be avoided in our future
> architecture, rather objects should be more atomic so we can use other
> patterns for pluggin in functionality/services etc ("strategies" et
> al). Hooks is the precursor for this idea.
I beg to differ: Inheritance should be used more often in the future. If
you build real objects with encapsulated methods and data, their
instances *are* atomic. However, this makes only sense if you use
classes for objects and not primarily as namesspaces. Of course, nobody
can be interested in inheriting from TCEmain or t3lib_div ;)
The flexibility should come from advanced factory functions that know
what to instanciate in what context. Kind of like makeinstance() on
steroids.
Greetings,
Michael
More information about the TYPO3-dev
mailing list