function FieldBlockDeriver::__construct

Same name in other branches
  1. 9 core/modules/layout_builder/src/Plugin/Derivative/FieldBlockDeriver.php \Drupal\layout_builder\Plugin\Derivative\FieldBlockDeriver::__construct()
  2. 8.9.x core/modules/layout_builder/src/Plugin/Derivative/FieldBlockDeriver.php \Drupal\layout_builder\Plugin\Derivative\FieldBlockDeriver::__construct()
  3. 10 core/modules/layout_builder/src/Plugin/Derivative/FieldBlockDeriver.php \Drupal\layout_builder\Plugin\Derivative\FieldBlockDeriver::__construct()

Constructs new FieldBlockDeriver.

Parameters

\Drupal\Core\Entity\EntityTypeRepositoryInterface $entity_type_repository: The entity type repository.

\Drupal\Core\Entity\EntityFieldManagerInterface $entity_field_manager: The entity field manager.

\Drupal\Core\Field\FieldTypePluginManagerInterface $field_type_manager: The field type manager.

\Drupal\Core\Field\FormatterPluginManager $formatter_manager: The formatter manager.

\Drupal\Core\Config\Entity\ConfigEntityStorageInterface $entityViewDisplayStorage: The entity view display storage.

\Drupal\Core\Extension\ModuleHandlerInterface $moduleHandler: The module handler.

File

core/modules/layout_builder/src/Plugin/Derivative/FieldBlockDeriver.php, line 76

Class

FieldBlockDeriver
Provides entity field block definitions for every field.

Namespace

Drupal\layout_builder\Plugin\Derivative

Code

public function __construct(EntityTypeRepositoryInterface $entity_type_repository, EntityFieldManagerInterface $entity_field_manager, FieldTypePluginManagerInterface $field_type_manager, FormatterPluginManager $formatter_manager, ConfigEntityStorageInterface $entityViewDisplayStorage, ModuleHandlerInterface $moduleHandler) {
    $this->entityTypeRepository = $entity_type_repository;
    $this->entityFieldManager = $entity_field_manager;
    $this->fieldTypeManager = $field_type_manager;
    $this->formatterManager = $formatter_manager;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.