function BlockRepositoryInterface::getVisibleBlocksPerRegion

Same name in other branches
  1. 9 core/modules/block/src/BlockRepositoryInterface.php \Drupal\block\BlockRepositoryInterface::getVisibleBlocksPerRegion()
  2. 8.9.x core/modules/block/src/BlockRepositoryInterface.php \Drupal\block\BlockRepositoryInterface::getVisibleBlocksPerRegion()
  3. 10 core/modules/block/src/BlockRepositoryInterface.php \Drupal\block\BlockRepositoryInterface::getVisibleBlocksPerRegion()

Returns an array of regions and their block entities.

Parameters

\Drupal\Core\Cache\CacheableMetadata[] $cacheable_metadata: (optional) List of CacheableMetadata objects, keyed by region. This is by reference and is used to pass this information back to the caller.

Return value

array The array is first keyed by region machine name, with the values containing an array keyed by block ID, with block entities as the values.

File

core/modules/block/src/BlockRepositoryInterface.php, line 32

Class

BlockRepositoryInterface

Namespace

Drupal\block

Code

public function getVisibleBlocksPerRegion(array &$cacheable_metadata = []);

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