public function DisplayBuilderManager::createInstance in Panels 8.4
Same name and namespace in other branches
- 8.3 src/Plugin/DisplayBuilder/DisplayBuilderManager.php \Drupal\panels\Plugin\DisplayBuilder\DisplayBuilderManager::createInstance()
Creates a pre-configured instance of a plugin.
Parameters
string $plugin_id: The ID of the plugin being instantiated.
array $configuration: An array of configuration relevant to the plugin instance.
Return value
object A fully configured plugin instance.
Throws
\Drupal\Component\Plugin\Exception\PluginException If the instance cannot be created, such as if the ID is invalid.
Overrides PluginManagerBase::createInstance
File
- src/
Plugin/ DisplayBuilder/ DisplayBuilderManager.php, line 33
Class
- DisplayBuilderManager
- The display builder plugin manager.
Namespace
Drupal\panels\Plugin\DisplayBuilderCode
public function createInstance($plugin_id, array $configuration = array()) {
// Redirect the deprecated editor builder to use the standard builder.
if ($plugin_id == 'editor') {
return parent::createInstance('standard', $configuration);
}
return parent::createInstance($plugin_id, $configuration);
}