You are here

public function IndeterminateBundleException::__construct in Varbase Media 8.7

Same name and namespace in other branches
  1. 8.5 modules/entity_browser_generic_embed/src/Exception/IndeterminateBundleException.php \Drupal\entity_browser_generic_embed\Exception\IndeterminateBundleException::__construct()
  2. 8.6 modules/entity_browser_generic_embed/src/Exception/IndeterminateBundleException.php \Drupal\entity_browser_generic_embed\Exception\IndeterminateBundleException::__construct()
  3. 9.0.x modules/entity_browser_generic_embed/src/Exception/IndeterminateBundleException.php \Drupal\entity_browser_generic_embed\Exception\IndeterminateBundleException::__construct()

IndeterminateBundleException constructor.

Parameters

mixed $value: The input value.

int $code: (optional) The error code.

\Exception|null $previous: (optional) The previous exception, if any.

File

modules/entity_browser_generic_embed/src/Exception/IndeterminateBundleException.php, line 22

Class

IndeterminateBundleException
Exception thrown if no bundle can be determined from an input value.

Namespace

Drupal\entity_browser_generic_embed\Exception

Code

public function __construct($value, $code = 0, \Exception $previous = NULL) {
  $message = sprintf('Could not match any bundles to input: %s', $value instanceof EntityInterface ? $value
    ->label() : var_export($value, TRUE));
  parent::__construct($message, $code, $previous);
}