[TYPO3-dev] Hooks and protected class members
Christian Opitz - Netzelf
christian.opitz at netzelf.de
Wed Sep 22 19:21:04 CEST 2010
Am 22.09.2010 15:04, schrieb Jigal van Hemert:
> We could try to set up such a construction where the class which
> provides the hook somehow (with the help of t3lib_div::makeInstance()
> perhaps) adds the class with the hook function to it's list of
> friends. This way the hook functions can access protected members
> through the __get and __set.
>
> Opinions?
Maybe a more generic way would be to enforce that a hook-class has to be
part of the class-"package" - means the first part of it's name must be
the name of the hook-provider-class. I've posted an example here:
http://pastebin.com/DDwrbVaH
Cheers,
Christian
More information about the TYPO3-dev
mailing list