class BadPluginDefinitionException in Drupal 9
Same name and namespace in other branches
- 8 core/modules/migrate/src/Plugin/Exception/BadPluginDefinitionException.php \Drupal\migrate\Plugin\Exception\BadPluginDefinitionException
Defines a class for bad plugin definition exceptions.
Hierarchy
- class \Drupal\Component\Plugin\Exception\PluginException extends \Drupal\Component\Plugin\Exception\Exception implements ExceptionInterface
- class \Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
- class \Drupal\migrate\Plugin\Exception\BadPluginDefinitionException
- class \Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
Expanded class hierarchy of BadPluginDefinitionException
4 files declare their use of BadPluginDefinitionException
- CredentialForm.php in core/
modules/ migrate_drupal_ui/ src/ Form/ CredentialForm.php - MigrateFieldPluginManager.php in core/
modules/ migrate_drupal/ src/ Plugin/ MigrateFieldPluginManager.php - MigrationPluginManager.php in core/
modules/ migrate_drupal/ src/ MigrationPluginManager.php - MigrationProvidersExistTest.php in core/
modules/ migrate/ tests/ src/ Kernel/ Plugin/ MigrationProvidersExistTest.php
File
- core/
modules/ migrate/ src/ Plugin/ Exception/ BadPluginDefinitionException.php, line 10
Namespace
Drupal\migrate\Plugin\ExceptionView source
class BadPluginDefinitionException extends InvalidPluginDefinitionException {
/**
* Constructs a BadPluginDefinitionException.
*
* @param string $plugin_id
* The plugin ID of the mapper.
* @param string $property
* The name of the property that is missing from the plugin.
* @param int $code
* (optional) The exception code. Defaults to 0.
* @param \Exception|null $previous
* The previous throwable used for exception chaining.
*
* @see \Exception
*/
public function __construct($plugin_id, $property, $code = 0, \Exception $previous = NULL) {
$message = sprintf('The %s plugin must define the %s property.', $plugin_id, $property);
parent::__construct($plugin_id, $message, $code, $previous);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BadPluginDefinitionException:: |
public | function |
Constructs a BadPluginDefinitionException. Overrides InvalidPluginDefinitionException:: |
|
InvalidPluginDefinitionException:: |
protected | property | The plugin ID of the mapper. | |
InvalidPluginDefinitionException:: |
public | function | Gets the plugin ID of the mapper that raised the exception. |