Package com.gengoai.hermes.corpus
Class Query
- java.lang.Object
-
- com.gengoai.hermes.corpus.Query
-
- All Implemented Interfaces:
Serializable
public abstract class Query extends Object implements Serializable
Defines the methodology for matching documents based on simple boolean logic over term and document level attributes.- Author:
- David B. Bracewell
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Query()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract boolean
matches(Document document)
Tests if the document matches the queryabstract org.apache.lucene.search.Query
toLucene()
Converts the Query into a Lucene Search Query
-
-
-
Method Detail
-
matches
public abstract boolean matches(Document document)
Tests if the document matches the query- Parameters:
document
- the document- Returns:
- True if the test passes, False if not
-
toLucene
public abstract org.apache.lucene.search.Query toLucene()
Converts the Query into a Lucene Search Query- Returns:
- the Lucene search Query
-
-