[TYPO3-core] Signals vs. Hooks

Philipp Gampe philipp.gampe at typo3.org
Sun Aug 24 21:10:16 CEST 2014

Hi Bernhard,

Bernhard Kraft wrote:

> Indeed, the GoF rather propose the "Template method" pattern for this
> purpose instead of the observer (signal) pattern:
> http://en.wikipedia.org/wiki/Template_method_pattern
> http://de.wikipedia.org/wiki/Schablonenmethode

This does not do what hooks do. Hooks allow various (more than one!) 
observer to alter the data that is processed further or alter it after 

This described method allows only one observer (subclass) to actually alter 
the data. It is a very good way to implement abstract algorithms to avoid 
code duplication in the implementing classes. However it does not solve to 
problem of allowing multiple observers for the same step.

Best regards
Philipp Gampe – PGP-Key 0AD96065 – TYPO3 UG Bonn/Köln
Documentation – Active contributor TYPO3 CMS
TYPO3 .... inspiring people to share!

More information about the TYPO3-team-core mailing list