Modifier and Type | Class and Description |
---|---|
protected class |
FunctionQuery.AllScorer |
protected class |
FunctionQuery.FunctionWeight |
Constructor and Description |
---|
FunctionQuery(ValueSource func) |
Modifier and Type | Method and Description |
---|---|
Weight |
createWeight(IndexSearcher searcher,
boolean needsScores)
Expert: Constructs an appropriate Weight implementation for this query.
|
boolean |
equals(Object o)
Returns true if
o is equal to this. |
ValueSource |
getValueSource() |
int |
hashCode() |
Query |
rewrite(IndexReader reader)
Expert: called to re-write queries into primitive queries.
|
String |
toString(String field)
Prints a user-readable version of this query.
|
public FunctionQuery(ValueSource func)
func
- defines the function to be used for scoringpublic ValueSource getValueSource()
public Query rewrite(IndexReader reader) throws IOException
Query
rewrite
in class Query
IOException
public Weight createWeight(IndexSearcher searcher, boolean needsScores) throws IOException
Query
Only implemented by primitive queries, which re-write to themselves.
createWeight
in class Query
needsScores
- True if document scores (Scorer.score()
) or match
frequencies (Scorer.freq()
) are needed.IOException
public boolean equals(Object o)
o
is equal to this.Copyright © 2000–2015 The Apache Software Foundation. All rights reserved.