| Modifier and Type | Class and Description |
|---|---|
private class |
OrNearSpans.SpansCell |
| Modifier and Type | Field and Description |
|---|---|
private static Comparator |
cellComparator |
private ArrayList |
cells |
private boolean |
firstTime |
private int |
matchDist |
private int |
matchEndCell |
private int |
matchNumCells |
private float |
matchTotalScore |
private boolean |
more |
private int |
nClauses |
private boolean |
penalizeOutOfOrder |
private SpanOrNearQuery |
query |
private Similarity |
similarity |
private int |
slop |
| Constructor and Description |
|---|
OrNearSpans(SpanOrNearQuery query,
IndexReader reader,
Searcher searcher) |
| Modifier and Type | Method and Description |
|---|---|
private boolean |
advance(int skipTo) |
int |
doc()
Returns the document number of the current match.
|
int |
end()
Returns the end position of the current match.
|
Explanation |
explain()
Returns an explanation of how the score was arrived at.
|
private boolean |
initCells(int skipTo) |
boolean |
next()
Move to the next match, returning true iff any such exists.
|
private boolean |
nextCell() |
float |
score()
Returns the score of the current match.
|
boolean |
skipTo(int target)
Skips to the first match beyond the current, whose document number is
greater than or equal to target.
|
int |
start()
Returns the start position of the current match.
|
String |
toString() |
private SpanOrNearQuery query
private Similarity similarity
private int nClauses
private ArrayList cells
private int slop
private boolean penalizeOutOfOrder
private boolean more
private boolean firstTime
private int matchDist
private float matchTotalScore
private int matchEndCell
private int matchNumCells
private static final Comparator cellComparator
public OrNearSpans(SpanOrNearQuery query, IndexReader reader, Searcher searcher) throws IOException
IOExceptionpublic boolean next()
throws IOException
Spansprivate boolean initCells(int skipTo)
throws IOException
IOExceptionprivate boolean advance(int skipTo)
throws IOException
IOExceptionprivate boolean nextCell()
public boolean skipTo(int target)
throws IOException
SpansReturns 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.public int doc()
Spanspublic int start()
Spanspublic int end()
Spanspublic float score()
Spanspublic String toString()
toString in class Object