Same name and namespace in other branches
  1. 8.9.x core/modules/search/src/Plugin/SearchPluginBase.php \Drupal\search\Plugin\SearchPluginBase::isSearchExecutable()
  2. 9 core/modules/search/src/Plugin/SearchPluginBase.php \Drupal\search\Plugin\SearchPluginBase::isSearchExecutable()

Verifies if the values set via setSearch() are valid and sufficient.

Return value

bool TRUE if the search settings are valid and sufficient to execute a search, and FALSE if not.

Overrides SearchInterface::isSearchExecutable

File

core/modules/search/src/Plugin/SearchPluginBase.php, line 82

Class

SearchPluginBase
Defines a base class for plugins wishing to support search.

Namespace

Drupal\search\Plugin

Code

public function isSearchExecutable() {

  // Default implementation suitable for plugins that only use keywords.
  return !empty($this->keywords);
}