[ Index ] |
PHP Cross Reference of Joomla 4.2.2 documentation |
[Summary view] [Print] [Text view]
1 <?php 2 3 /* 4 * This file is part of the Symfony package. 5 * 6 * (c) Fabien Potencier <[email protected]> 7 * 8 * For the full copyright and license information, please view the LICENSE 9 * file that was distributed with this source code. 10 */ 11 12 namespace Symfony\Component\ErrorHandler; 13 14 use Symfony\Component\ErrorHandler\Exception\SilencedErrorContext; 15 16 /** 17 * @internal 18 */ 19 class ThrowableUtils 20 { 21 /** 22 * @param SilencedErrorContext|\Throwable 23 */ 24 public static function getSeverity($throwable): int 25 { 26 if ($throwable instanceof \ErrorException || $throwable instanceof SilencedErrorContext) { 27 return $throwable->getSeverity(); 28 } 29 30 if ($throwable instanceof \ParseError) { 31 return \E_PARSE; 32 } 33 34 if ($throwable instanceof \TypeError) { 35 return \E_RECOVERABLE_ERROR; 36 } 37 38 return \E_ERROR; 39 } 40 }
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Wed Sep 7 05:41:13 2022 | Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer |