Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. WithLogLevel.php

function WithLogLevel::__construct

Parameters

LogLevel::* $level The level to use to log the exception:

File

vendor/symfony/http-kernel/Attribute/WithLogLevel.php, line 27

Class

WithLogLevel
Defines the log level applied to an exception.

Namespace

Symfony\Component\HttpKernel\Attribute

Code

public function __construct(string $level) {
    if (!\defined('Psr\\Log\\LogLevel::' . strtoupper($this->level))) {
        throw new \InvalidArgumentException(\sprintf('Invalid log level "%s".', $this->level));
    }
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal