You are here

public function LayoutBuilder::__construct in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/layout_builder/src/Element/LayoutBuilder.php \Drupal\layout_builder\Element\LayoutBuilder::__construct()
  2. 9 core/modules/layout_builder/src/Element/LayoutBuilder.php \Drupal\layout_builder\Element\LayoutBuilder::__construct()

Constructs a new LayoutBuilder.

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.

\Symfony\Contracts\EventDispatcher\EventDispatcherInterface $event_dispatcher: The event dispatcher service.

Overrides PluginBase::__construct

File

core/modules/layout_builder/src/Element/LayoutBuilder.php, line 52

Class

LayoutBuilder
Defines a render element for building the Layout Builder UI.

Namespace

Drupal\layout_builder\Element

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, EventDispatcherInterface $event_dispatcher) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->eventDispatcher = $event_dispatcher;
}