PHP Class Elastica\Query\SimpleQueryString

Inheritance: extends AbstractQuery
Datei anzeigen Open project: ruflin/elastica Class Usage Examples

Public Methods

Method Description
__construct ( string $query, array $fields = [] )
setAnalyzer ( string $analyzer ) Set the analyzer used to analyze each term of the query.
setDefaultOperator ( string $operator ) Set the default operator to use if no explicit operator is defined in the query string.
setFields ( array $fields )
setMinimumShouldMatch ( integer | string $minimumShouldMatch ) Set minimum_should_match option.
setQuery ( string $query ) Set the querystring for this query.

Method Details

__construct() public method

public __construct ( string $query, array $fields = [] )
$query string
$fields array

setAnalyzer() public method

Set the analyzer used to analyze each term of the query.
public setAnalyzer ( string $analyzer )
$analyzer string

setDefaultOperator() public method

Set the default operator to use if no explicit operator is defined in the query string.
public setDefaultOperator ( string $operator )
$operator string see OPERATOR_* constants for options

setFields() public method

public setFields ( array $fields )
$fields array the fields on which to perform this query. Defaults to index.query.default_field.

setMinimumShouldMatch() public method

Set minimum_should_match option.
public setMinimumShouldMatch ( integer | string $minimumShouldMatch )
$minimumShouldMatch integer | string

setQuery() public method

Set the querystring for this query.
public setQuery ( string $query )
$query string see ES documentation for querystring syntax