Esempio n. 1
0
 /**
  * Registers a function to be called if no custom handlers are defined
  *
  * This method allows a callable function to be called for standard errors
  * (i.e. NX_ERROR_FATAL, NX_ERROR_WARNING) to override the default actions.
  * Note that if a custom handler for an error is defined in the Error:init()
  * arguments, this function will never be called.
  * This function should accept 1 argument: reference to the current Error
  *
  * @param mixed $_handler a function or an array of class=>method
  *
  * @return null
  */
 public static function registerDefaultHandler($_handler)
 {
     if (is_callable($_handler)) {
         self::$_defaultHandler = $_handler;
     } else {
         Nexista_Error::init("Error Default Handler is not callable!");
     }
 }