- \PHPUnit_Util_ErrorHandler
class (none) \ PHPUnit_Util_ErrorHandler
Error handler that converts PHP errors and warnings to exceptions.
Method Summary
Name | Description |
---|---|
getErrorStack() | Returns the error stack. |
handleError($errno, $errstr, $errfile, $errline) | |
handleErrorOnce($severity = E_WARNING) | Registers an error handler and returns a function that will restore the previous handler when invoked |
public static function getErrorStack()
Returns the error stack.
- Returns:
- array
public static function handleError($errno, $errstr, $errfile, $errline)
- Parameters:
integer
- $errlinestring
- $errfile- Throws:
- PHPUnit_Framework_Error
public static function handleErrorOnce($severity = E_WARNING)
Registers an error handler and returns a function that will restore the previous handler when invoked
- Parameters:
integer
- $severity PHP predefined error constant- Defaults:
severity
=E_WARNING
- Throws:
- Exception - if event of specified severity is emitted