You are here

public static function Server::supportsSearch in Search API Autocomplete 8

Determines whether this plugin supports the given search.

Parameters

\Drupal\search_api_autocomplete\SearchInterface $search: The search in question.

Return value

bool TRUE if this plugin supports the given search, FALSE otherwise.

Overrides SuggesterPluginBase::supportsSearch

File

src/Plugin/search_api_autocomplete/suggester/Server.php, line 51

Class

Server
Provides a suggester plugin that retrieves suggestions from the server.

Namespace

Drupal\search_api_autocomplete\Plugin\search_api_autocomplete\suggester

Code

public static function supportsSearch(SearchInterface $search) {
  return (bool) static::getBackend($search
    ->getIndex());
}