You are here

public function Query::__construct in Search API Solr 4.x

Same name and namespace in other branches
  1. 8.3 src/Solarium/Autocomplete/Query.php \Drupal\search_api_solr\Solarium\Autocomplete\Query::__construct()
  2. 8 src/Solarium/Autocomplete/Query.php \Drupal\search_api_solr\Solarium\Autocomplete\Query::__construct()
  3. 8.2 src/Solarium/Autocomplete/Query.php \Drupal\search_api_solr\Solarium\Autocomplete\Query::__construct()

Constructs a Query object.

File

src/Solarium/Autocomplete/Query.php, line 40

Class

Query
Autocomplete query.

Namespace

Drupal\search_api_solr\Solarium\Autocomplete

Code

public function __construct($options = NULL) {
  $this->componentTypes = [
    ComponentAwareQueryInterface::COMPONENT_SPELLCHECK => Spellcheck::class,
    ComponentAwareQueryInterface::COMPONENT_SUGGESTER => Suggester::class,
    ComponentAwareQueryInterface::COMPONENT_TERMS => Terms::class,
  ];
  parent::__construct($options);
}