You are here

protected function BlockVariantTrait::getBlockCollection in Chaos Tool Suite (ctools) 8.3

Returns the block plugins used for this display variant.

Return value

\Drupal\Core\Block\BlockPluginInterface[]|\Drupal\ctools\Plugin\BlockPluginCollection An array or collection of configured block plugins.

1 call to BlockVariantTrait::getBlockCollection()
BlockDisplayVariant::calculateDependencies in src/Plugin/DisplayVariant/BlockDisplayVariant.php
Calculates dependencies for the configured plugin.

File

src/Plugin/BlockVariantTrait.php, line 136

Class

BlockVariantTrait
Provides methods for \Drupal\ctools\Plugin\BlockVariantInterface.

Namespace

Drupal\ctools\Plugin

Code

protected function getBlockCollection() {
  if (!$this->blockPluginCollection) {
    $this->blockPluginCollection = new BlockPluginCollection($this
      ->getBlockManager(), $this
      ->getBlockConfig());
  }
  return $this->blockPluginCollection;
}