protected function FormElementComponent::getPlugin in Flexiform 8
Get the form element plugin.
1 call to FormElementComponent::getPlugin()
- FormElementComponent::settingsForm in src/
Plugin/ FormComponentType/ FormElementComponent.php - Get the settings form.
File
- src/
Plugin/ FormComponentType/ FormElementComponent.php, line 73
Class
- FormElementComponent
- Component class for field widgets.
Namespace
Drupal\flexiform\Plugin\FormComponentTypeCode
protected function getPlugin() {
if (empty($this->plugin)) {
$this->plugin = $this->pluginManager
->createInstance($this->options['form_element'], $this->options['settings']);
if ($this->plugin instanceof ContextAwarePluginInterface) {
$this->contextHandler
->applyContextMapping($this->plugin, $this
->getFormEntityManager()
->getContexts());
}
}
return $this->plugin;
}