[TYPO3-mvc] Proposal: mixed-ins for extbase
Franz Koch
typo3.RemoveForMessage at elements-net.de
Fri Sep 3 03:24:59 CEST 2010
Hey Helmut,
...
the concept sounds nice, but also has a downside, see below:
> Disadvantages:
> * The autoloader is probably not the nicest place to have this
> functionality (however it would be possible to implement it into an
> object manager).
>
> * It will be difficult to have proper error handling, giving nice errors
> if the mixin conflicts with already defined methods or properties.
that wouldn't be such a big loss compared to the benefits I think.
> * It is not possible to override methods within a mixin (which might be
> a bad idea anyways)
I think this has to be possible via whatever approach - so the current
concept is not yet a final solution and needs some more thoughts.
Just an example. Imagine you're extending a existing extension and add
some new properties etc. Now imagine the domain model itself contains
some domain logic you're additions also depend on. So you need a way to
"hook" in there.
Or just imagine your new properties depend on another one and you
yourself need to add domain logic to a existing setter in order to
fulfill a dependency in your added property.
So there definitely has to be a way to override or better extend functions.
--
kind regards,
Franz Koch
More information about the TYPO3-project-typo3v4mvc
mailing list