performance - PHP Hook Function -
can like:
register_function_hook('myfunctionhook');
so when function run:
functiona(); //the hook runs myfunctionhook(); anoterfunction(); //the hook runs myfunctionhook(); class::functiona(); //the hook runs myfunctionhook();
does such thing exist?
-- edit --
what want breakdown of durations of each function. ie. performance tuning. want idea of takes time without installing xdebug on apache server, don't know if possible.
no, not possible way like
but can achieve close inheritance.
class vehicle { function __construct() { $this->hookfunction(); } function hookfunction() { // } } class car extends vehicle { } class toyota extends car { } new toyota(); // hook function // exclude static call member functions, or other inline functions.
Comments
Post a Comment