function DisplayLink::hasEqualOptions

Same name in other branches
  1. 8.9.x core/modules/views/src/Plugin/views/area/DisplayLink.php \Drupal\views\Plugin\views\area\DisplayLink::hasEqualOptions()
  2. 10 core/modules/views/src/Plugin/views/area/DisplayLink.php \Drupal\views\Plugin\views\area\DisplayLink::hasEqualOptions()
  3. 11.x core/modules/views/src/Plugin/views/area/DisplayLink.php \Drupal\views\Plugin\views\area\DisplayLink::hasEqualOptions()

Check if the options of a views display are equal to the current display.

Parameters

string $display_id: The display ID to check.

string $option: The option to check.

Return value

bool Whether the option of the view display are equal to the current display or not.

1 call to DisplayLink::hasEqualOptions()
DisplayLink::validate in core/modules/views/src/Plugin/views/area/DisplayLink.php
Validate that the plugin is correct and can be saved.

File

core/modules/views/src/Plugin/views/area/DisplayLink.php, line 237

Class

DisplayLink
Views area display_link handler.

Namespace

Drupal\views\Plugin\views\area

Code

protected function hasEqualOptions($display_id, $option) {
    $loaded_display = $this->view->displayHandlers
        ->get($display_id);
    return $loaded_display->getOption($option) === $this->displayHandler
        ->getOption($option);
}

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