BooleanQuery

A Query that matches documents matching boolean combinations of other queries, e.g. [ ]s, PhraseQuerys or other BooleanQuerys.

Types

Link copied to clipboard
class Builder

A builder for boolean queries.

Properties

Link copied to clipboard
Link copied to clipboard

Gets the minimum number of the optional BooleanClauses which must be satisfied.

Functions

Link copied to clipboard

Return a list of the clauses of this BooleanQuery.

Link copied to clipboard
open override fun createWeight(searcher: IndexSearcher, scoreMode: ScoreMode, boost: Float): Weight

Expert: Constructs an appropriate Weight implementation for this query.

Link copied to clipboard
open operator override fun equals(o: Any?): Boolean

Compares the specified object with this boolean query for equality. Returns true if and only if the provided object

Link copied to clipboard

Return the collection of queries for the given Occur.

Link copied to clipboard
open override fun hashCode(): Int

Override and implement query hash code properly in a subclass. This is required so that [ ] works properly.

Link copied to clipboard
open operator override fun iterator(): MutableIterator<BooleanClause>

Returns an iterator on the clauses in this query. It implements the Iterable interface to make it possible to do:

Link copied to clipboard
open override fun rewrite(indexSearcher: IndexSearcher): Query

Expert: called to re-write queries into primitive queries. For example, a PrefixQuery will be rewritten into a BooleanQuery that consists of TermQuerys.

Link copied to clipboard

Rewrite a single two clause disjunction query with terms to two term queries and a conjunction query using the inclusion–exclusion principle.

Link copied to clipboard
open override fun toString(field: String?): String

Prints a user-readable version of this query.

open override fun toString(): String

Prints a query to a string.

Link copied to clipboard
open override fun visit(visitor: QueryVisitor)

Recurse through the query tree, visiting any child queries.