You are here

public function IndexInterface::query in Search API 8

Creates a query object for this index.

Parameters

array $options: (optional) Associative array of options configuring this query.

Return value

\Drupal\search_api\Query\QueryInterface A query object for searching this index.

Throws

\Drupal\search_api\SearchApiException Thrown if the index is currently disabled or its server doesn't exist.

See also

\Drupal\search_api\Query\QueryInterface::create()

2 methods override IndexInterface::query()
Index::query in src/Entity/Index.php
Creates a query object for this index.
UnsavedIndexConfiguration::query in src/UnsavedIndexConfiguration.php
Creates a query object for this index.

File

src/IndexInterface.php, line 741

Class

IndexInterface
Defines the interface for index entities.

Namespace

Drupal\search_api

Code

public function query(array $options = []);