private static function install($errorHandler) { array_push(self::$currentHandlerStack, $errorHandler); // Install error handlers set_error_handler(array('ErrorManager', 'errorHandlerRaiseErrorExceptionHandler'), self::HANDLED_ERRORS); if (!self::$shutdownErrorDetectorInstalled) { register_shutdown_function(array('ErrorManager', 'shutdownErrorDetector')); self::$shutdownErrorDetectorInstalled = true; } self::$shutdownErrorDetectorEnabled = true; // fire our "ignore" error, make sure it doesn't show // @ supresses OUTPUT but error will still call error handlers and appear in error_get_last @trigger_error(self::IGNORED_ERROR, E_USER_NOTICE); }