Block::getVisibilityConditions

public Block::getVisibilityConditions()

Gets conditions for this block.

Return value

\Drupal\Core\Condition\ConditionInterface[]|\Drupal\Core\Condition\ConditionPluginCollection An array or collection of configured condition plugins.

Overrides BlockInterface::getVisibilityConditions

File

core/modules/block/src/Entity/Block.php, line 273

Class

Block
Defines a Block configuration entity class.

Namespace

Drupal\block\Entity

Code

public function getVisibilityConditions() {
  if (!isset($this->visibilityCollection)) {
    $this->visibilityCollection = new ConditionPluginCollection($this->conditionPluginManager(), $this->get('visibility'));
  }
  return $this->visibilityCollection;
}
doc_Drupal
2016-10-29 08:46:29
Comments
Leave a Comment

Please login to continue.