public function ViewmodepagePattern::getSelectionConditions in View Mode Page 3.2.x
Same name and namespace in other branches
- 8.3 src/Entity/ViewmodepagePattern.php \Drupal\view_mode_page\Entity\ViewmodepagePattern::getSelectionConditions()
- 4.0.x src/Entity/ViewmodepagePattern.php \Drupal\view_mode_page\Entity\ViewmodepagePattern::getSelectionConditions()
Gets the selection condition collection.
Return value
\Drupal\Core\Condition\ConditionInterface[]|\Drupal\Core\Condition\ConditionPluginCollection Returns a array/collection of condition objects
Overrides ViewmodepagePatternInterface::getSelectionConditions
3 calls to ViewmodepagePattern::getSelectionConditions()
- ViewmodepagePattern::applies in src/
Entity/ ViewmodepagePattern.php - Determines if this pattern can apply a given object.
- ViewmodepagePattern::calculateDependencies in src/
Entity/ ViewmodepagePattern.php - Calculates dependencies and stores them in the dependency property.
- ViewmodepagePattern::preSave in src/
Entity/ ViewmodepagePattern.php - Not using core's default logic around ConditionPluginCollection since it incorrectly assumes no condition will ever be applied twice.
File
- src/
Entity/ ViewmodepagePattern.php, line 282
Class
- ViewmodepagePattern
- Defines the Viewmodepage pattern entity.
Namespace
Drupal\view_mode_page\EntityCode
public function getSelectionConditions() {
if (!$this->selectionConditionCollection) {
$this->selectionConditionCollection = new ConditionPluginCollection(\Drupal::service('plugin.manager.condition'), $this
->get('selection_criteria'));
}
return $this->selectionConditionCollection;
}