I still fully maintain that entirely static classes is the most useless
thing and is just an extremely crude method of hiding global context. We're
using PHP 5.3 in the core, might as well just use namespaces at that point,
because that's what a static class is: a namespace with global variables
and functions. It entirely defeats the purpose of object oriented
programming.

Nonetheless, I don't see any other good way to implement Hooks other than
as a global state. Even though there are times where hooks are executing in
a context, like Daniel said, there are times where they are not, e.g.,
maintenance scripts or any other place outside the normal request/response
workflow.

*-- *
*Tyler Romeo*
Stevens Institute of Technology, Class of 2015
Major in Computer Science
www.whizkidztech.com | tylerro...@gmail.com
_______________________________________________
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to