function MigrateException::__construct

Same name in other branches
  1. 9 core/modules/migrate/src/MigrateException.php \Drupal\migrate\MigrateException::__construct()
  2. 8.9.x core/modules/migrate/src/MigrateException.php \Drupal\migrate\MigrateException::__construct()
  3. 11.x core/modules/migrate/src/MigrateException.php \Drupal\migrate\MigrateException::__construct()

Constructs a MigrateException object.

Parameters

string $message: The message for the exception.

int $code: The Exception code.

\Exception $previous: The previous exception used for the exception chaining.

int $level: The level of the error, a Migration::MESSAGE_* constant.

int $status: The status of the item for the map table, a MigrateMap::STATUS_* constant.

1 call to MigrateException::__construct()
EntityValidationException::__construct in core/modules/migrate/src/Exception/EntityValidationException.php
EntityValidationException constructor.
1 method overrides MigrateException::__construct()
EntityValidationException::__construct in core/modules/migrate/src/Exception/EntityValidationException.php
EntityValidationException constructor.

File

core/modules/migrate/src/MigrateException.php, line 50

Class

MigrateException
Defines the migrate exception class.

Namespace

Drupal\migrate

Code

public function __construct($message = '', $code = 0, ?\Exception $previous = NULL, $level = MigrationInterface::MESSAGE_ERROR, $status = MigrateIdMapInterface::STATUS_FAILED) {
    $this->level = $level;
    $this->status = $status;
    parent::__construct($message);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.