public function NodeFormBlock::__construct in Form Block 2.0.x
Same name and namespace in other branches
- 8 src/Plugin/Block/NodeFormBlock.php \Drupal\formblock\Plugin\Block\NodeFormBlock::__construct()
Constructs a new NodeFormBlock plugin.
Parameters
array $configuration: A configuration array containing information about the plugin instance.
string $plugin_id: The plugin_id for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
\Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager: The entity manager.
\Drupal\Core\Entity\EntityFormBuilderInterface $entityFormBuilder: The entity form builder.
\Drupal\Core\Entity\EntityDisplayRepositoryInterface $entity_display_repository: The Entity Display Repository.
Overrides BlockPluginTrait::__construct
File
- src/
Plugin/ Block/ NodeFormBlock.php, line 67
Class
- NodeFormBlock
- Provides a block for node forms.
Namespace
Drupal\formblock\Plugin\BlockCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entityTypeManager, EntityFormBuilderInterface $entityFormBuilder, EntityDisplayRepositoryInterface $entity_display_repository) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this
->setConfiguration($configuration);
$this->entityTypeManager = $entityTypeManager;
$this->entityFormBuilder = $entityFormBuilder;
$this->entityDisplayRepository = $entity_display_repository;
}