public function SearchApiAutocompleteSearch::server in Search API Autocomplete 7
Retrieves the server this search would at the moment be executed on.
Return value
SearchApiServer The server this search would at the moment be executed on.
Throws
SearchApiException If a server is set for the index but it doesn't exist.
File
- ./
search_api_autocomplete.entity.php, line 113 - Contains SearchApiAutocompleteSearch.
Class
- SearchApiAutocompleteSearch
- Describes the autocomplete settings for a certain search.
Code
public function server() {
if (!isset($this->server)) {
if (!$this
->index() || !$this
->index()->server) {
$this->server = FALSE;
}
else {
$this->server = $this
->index()
->server();
if (!$this->server) {
$this->server = FALSE;
}
}
}
return $this->server;
}