You are here

public function SelectionDisplayBase::checkPreselectionSupport in Entity Browser 8

Same name and namespace in other branches
  1. 8.2 src/SelectionDisplayBase.php \Drupal\entity_browser\SelectionDisplayBase::checkPreselectionSupport()

Check does selection display support preselection.

If preselection is not allowed by entity browser selection display, then exception will be thrown.

Throws

\Drupal\Core\Config\ConfigException

Overrides SelectionDisplayInterface::checkPreselectionSupport

Deprecated

Use ::supportsPreselection instead.

File

src/SelectionDisplayBase.php, line 132

Class

SelectionDisplayBase
Base implementation for selection display plugins.

Namespace

Drupal\entity_browser

Code

public function checkPreselectionSupport() {
  @trigger_error('checkPreselectionSupport method is deprecated. Use supportsPreselection instead.', E_USER_DEPRECATED);
  if (!$this
    ->getPluginDefinition()['acceptPreselection']) {
    throw new ConfigException('Used entity browser selection display does not support preselection.');
  }
}