|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jackrabbit.core.query.lucene.AbstractQueryHits
org.apache.jackrabbit.core.query.lucene.SortedLuceneQueryHits
public final class SortedLuceneQueryHits
Wraps a lucene query result and adds a close method that allows to release resources after a query has been executed and the results have been read completely.
| Constructor Summary | |
|---|---|
SortedLuceneQueryHits(org.apache.lucene.index.IndexReader reader,
JackrabbitIndexSearcher searcher,
org.apache.lucene.search.Query query,
org.apache.lucene.search.Sort sort,
long resultFetchHint)
Creates a new QueryHits instance wrapping hits. |
|
| Method Summary | |
|---|---|
int |
getSize()
This default implementation returns -1. |
ScoreNode |
nextScoreNode()
Returns the next score node in this QueryHits or null if
there are no more score nodes. |
void |
skip(int n)
Skips n hits. |
| Methods inherited from class org.apache.jackrabbit.core.query.lucene.AbstractQueryHits |
|---|
close |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SortedLuceneQueryHits(org.apache.lucene.index.IndexReader reader,
JackrabbitIndexSearcher searcher,
org.apache.lucene.search.Query query,
org.apache.lucene.search.Sort sort,
long resultFetchHint)
throws IOException
QueryHits instance wrapping hits.
reader - the IndexReader in use.searcher - the index searcher.query - the query to execute.sort - the sort criteria.resultFetchHint - a hint on how many results should be fetched.
IOException - if an error occurs while reading from the index.| Method Detail |
|---|
public int getSize()
-1.
getSize in interface CloseableHitsgetSize in class AbstractQueryHits-1.
public ScoreNode nextScoreNode()
throws IOException
null if
there are no more score nodes.
IOException - if an error occurs while reading from the index.
public void skip(int n)
throws IOException
n hits.
skip in interface CloseableHitsskip in class AbstractQueryHitsn - the number of hits to skip.
IOException - if an error occurs while skipping.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||