function Callback::__construct
Same name in other branches
- 9 core/modules/migrate/src/Plugin/migrate/process/Callback.php \Drupal\migrate\Plugin\migrate\process\Callback::__construct()
- 8.9.x core/modules/migrate/src/Plugin/migrate/process/Callback.php \Drupal\migrate\Plugin\migrate\process\Callback::__construct()
- 11.x core/modules/migrate/src/Plugin/migrate/process/Callback.php \Drupal\migrate\Plugin\migrate\process\Callback::__construct()
File
-
core/
modules/ migrate/ src/ Plugin/ migrate/ process/ Callback.php, line 83
Class
- Callback
- Passes the source value to a callback.
Namespace
Drupal\migrate\Plugin\migrate\processCode
public function __construct(array $configuration, $plugin_id, $plugin_definition) {
if (!isset($configuration['callable'])) {
throw new \InvalidArgumentException('The "callable" must be set.');
}
elseif (!is_callable($configuration['callable'])) {
throw new \InvalidArgumentException('The "callable" must be a valid function or method.');
}
parent::__construct($configuration, $plugin_id, $plugin_definition);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.