public static function parseLevel(string $level): int
    {
        if (isset(self::$levels[$level])) {
            return self::$levels[$level];
        }

        throw new InvalidArgumentException('Invalid log level.');
    }
public static function parseLevel(string $level): int
    {
        if (isset(self::$levels[$level])) {
            return self::$levels[$level];
        }

        throw new InvalidArgumentException('Invalid log level.');
    }
public static function parseLevel ( string $ level ) : int { if ( isset ( self :: $ levels [ $ level ] ) ) { return self :: $ levels [ $ level ] ; } throw new InvalidArgumentException ( 'Invalid log level.' ) ; }
Parse the string level into a Monolog constant.

@param string $level

@throws \InvalidArgumentException

@return int
Parse the string level into a Monolog constant .