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

Breadcrumb

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

function Catch_::__construct

Constructs a catch node.

Parameters

Node\Name[] $types Types of exceptions to catch:

Expr\Variable|null $var Variable for exception:

Node\Stmt[] $stmts Statements:

array<string, mixed> $attributes Additional attributes:

File

vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php, line 24

Class

Catch_

Namespace

PhpParser\Node\Stmt

Code

public function __construct(array $types, ?Expr\Variable $var = null, array $stmts = [], array $attributes = []) {
    $this->attributes = $attributes;
    $this->types = $types;
    $this->var = $var;
    $this->stmts = $stmts;
}

API Navigation

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