|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgate.creole.annic.apache.lucene.search.Scorer
gate.creole.annic.apache.lucene.search.PhraseScorer
abstract class PhraseScorer
| Field Summary | |
|---|---|
protected PhrasePositions |
first
|
private boolean |
firstTime
|
private float |
freq
|
protected PhrasePositions |
last
|
private boolean |
more
|
protected byte[] |
norms
|
protected PhraseQueue |
pq
|
protected float |
value
|
private Weight |
weight
|
| Fields inherited from class gate.creole.annic.apache.lucene.search.Scorer |
|---|
searcher |
| Constructor Summary | |
|---|---|
PhraseScorer(Weight weight,
TermPositions[] tps,
Similarity similarity,
byte[] norms)
|
|
PhraseScorer(Weight weight,
TermPositions[] tps,
Vector positions,
Similarity similarity,
byte[] norms,
Searcher searcher)
|
|
| Method Summary | |
|---|---|
int |
doc()
Returns the current document number. |
private boolean |
doNext()
|
Explanation |
explain(int doc)
Returns an explanation of the score for doc. |
protected void |
firstToLast()
|
private void |
init()
|
boolean |
next(Searcher searcher)
Advance to the next document matching the query. |
protected abstract float |
phraseFreq()
|
protected void |
pqToList()
|
float |
score(Searcher searcher)
Returns the score of the current document. |
boolean |
skipTo(int target)
Skips to the first match beyond the current whose document number is greater than or equal to target. |
private void |
sort()
|
String |
toString()
|
| Methods inherited from class gate.creole.annic.apache.lucene.search.Scorer |
|---|
getSimilarity, score |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private Weight weight
protected byte[] norms
protected float value
private boolean firstTime
private boolean more
protected PhraseQueue pq
protected PhrasePositions first
protected PhrasePositions last
private float freq
| Constructor Detail |
|---|
PhraseScorer(Weight weight,
TermPositions[] tps,
Vector positions,
Similarity similarity,
byte[] norms,
Searcher searcher)
throws IOException
IOException
PhraseScorer(Weight weight,
TermPositions[] tps,
Similarity similarity,
byte[] norms)
throws IOException
IOException| Method Detail |
|---|
public int doc()
Scorer#next() is called the first time.
doc in class Scorer
public boolean next(Searcher searcher)
throws IOException
Scorer
next in class ScorerIOException
private boolean doNext()
throws IOException
IOException
public float score(Searcher searcher)
throws IOException
Scorer#next() is called the first time.
score in class ScorerIOException
public boolean skipTo(int target)
throws IOException
ScorerReturns true iff there is such a match.
Behaves as if written:
boolean skipTo(int target) {
do {
if (!next())
return false;
} while (target > doc());
return true;
}
Most implementations are considerably more efficient than that.
skipTo in class ScorerIOException
protected abstract float phraseFreq()
throws IOException
IOException
private void init()
throws IOException
IOExceptionprivate void sort()
protected final void pqToList()
protected final void firstToLast()
public Explanation explain(int doc)
throws IOException
Scorerdoc.
explain in class ScorerIOExceptionpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||