public function Query::range in Search API 8
Adds a range of results to return.
This will be saved in the query's options. If called without parameters, this will remove all range restrictions previously set.
Parameters
int|null $offset: The zero-based offset of the first result returned.
int|null $limit: The number of results to return.
Return value
$this
Overrides QueryInterface::range
File
- src/
Query/ Query.php, line 474
Class
- Query
- Provides a standard implementation for a Search API query.
Namespace
Drupal\search_api\QueryCode
public function range($offset = NULL, $limit = NULL) {
$this->options['offset'] = $offset;
$this->options['limit'] = $limit;
return $this;
}