You are here

public function BlockPluginTrait::__construct in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Block/BlockPluginTrait.php \Drupal\Core\Block\BlockPluginTrait::__construct()
  2. 9 core/lib/Drupal/Core/Block/BlockPluginTrait.php \Drupal\Core\Block\BlockPluginTrait::__construct()
4 methods override BlockPluginTrait::__construct()
AjaxFormBlock::__construct in core/modules/system/tests/modules/ajax_forms_test/src/Plugin/Block/AjaxFormBlock.php
Constructs a new AjaxFormBlock.
RedirectFormBlock::__construct in core/modules/system/tests/modules/form_test/src/Plugin/Block/RedirectFormBlock.php
Constructs a new RedirectFormBlock.
TestAccessBlock::__construct in core/modules/block/tests/modules/block_test/src/Plugin/Block/TestAccessBlock.php
Tests the test access block.
TestFormApiFormBlock::__construct in core/modules/layout_builder/tests/modules/layout_builder_form_block_test/src/Plugin/Block/TestFormApiFormBlock.php
TestFormApiFormBlock constructor.

File

core/lib/Drupal/Core/Block/BlockPluginTrait.php, line 64

Class

BlockPluginTrait
Provides the base implementation of a block plugin.

Namespace

Drupal\Core\Block

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this
    ->setConfiguration($configuration);
}