You are here

public function Search::getOption in Search API Autocomplete 8

Gets a specific option's value.

Parameters

string $key: The key of the option.

Return value

mixed|null The option's value, or NULL if the option is unknown.

Overrides SearchInterface::getOption

File

src/Entity/Search.php, line 366

Class

Search
Describes the autocomplete settings for a certain search.

Namespace

Drupal\search_api_autocomplete\Entity

Code

public function getOption($name) {
  $options = $this
    ->getOptions();
  return isset($options[$name]) ? $options[$name] : NULL;
}