public static function throwErrorException($errno, $errstr, $errfile, $errline)
    {
        if (error_reporting() & $errno) { //check if error level is set
            throw new \ErrorException(
                sprintf('%s: %s', self::getErrorTypeString($errno), $errstr),
                0,
                $errno,
                $errfile,
                $errline
            );
        }
    }
public static function throwErrorException($errno, $errstr, $errfile, $errline)
    {
        if (error_reporting() & $errno) { //check if error level is set
            throw new \ErrorException(
                sprintf('%s: %s', self::getErrorTypeString($errno), $errstr),
                0,
                $errno,
                $errfile,
                $errline
            );
        }
    }
public static function throwErrorException ( $ errno , $ errstr , $ errfile , $ errline ) { if ( error_reporting ( ) & $ errno ) { //check if error level is set throw new \ ErrorException ( sprintf ( '%s: %s' , self :: getErrorTypeString ( $ errno ) , $ errstr ) , 0 , $ errno , $ errfile , $ errline ) ; } }
Throws ErrorException.

@param int $errno Error level
@param string $errstr Error message
@param string $errfile Filename the error was raised in
@param int $errline Line number the error was raised at

@throws \ErrorException
Throws ErrorException .