function BlockPageVariant::__construct
Same name in other branches
- 9 core/modules/block/src/Plugin/DisplayVariant/BlockPageVariant.php \Drupal\block\Plugin\DisplayVariant\BlockPageVariant::__construct()
- 8.9.x core/modules/block/src/Plugin/DisplayVariant/BlockPageVariant.php \Drupal\block\Plugin\DisplayVariant\BlockPageVariant::__construct()
- 11.x core/modules/block/src/Plugin/DisplayVariant/BlockPageVariant.php \Drupal\block\Plugin\DisplayVariant\BlockPageVariant::__construct()
Constructs a new BlockPageVariant.
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\block\BlockRepositoryInterface $block_repository: The block repository.
\Drupal\Core\Entity\EntityViewBuilderInterface $block_view_builder: The block view builder.
string[] $block_list_cache_tags: The Block entity type list cache tags.
Overrides VariantBase::__construct
File
-
core/
modules/ block/ src/ Plugin/ DisplayVariant/ BlockPageVariant.php, line 86
Class
- BlockPageVariant
- Provides a page display variant that decorates the main content with blocks.
Namespace
Drupal\block\Plugin\DisplayVariantCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, BlockRepositoryInterface $block_repository, EntityViewBuilderInterface $block_view_builder, array $block_list_cache_tags) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->blockRepository = $block_repository;
$this->blockViewBuilder = $block_view_builder;
$this->blockListCacheTags = $block_list_cache_tags;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.