|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jackrabbit.core.query.lucene.QueryResultImpl
public abstract class QueryResultImpl
Implements the QueryResult
interface.
Field Summary | |
---|---|
protected AccessManager |
accessMgr
The access manager of the session that executes the query. |
protected boolean |
docOrder
If true nodes are returned in document order. |
protected SearchIndex |
index
The search index to execute the query. |
protected ItemManager |
itemMgr
The item manager of the session executing the query |
protected Path[] |
orderProps
The relative paths of properties to use for ordering the result set. |
protected boolean[] |
orderSpecs
The order specifier for each of the order properties. |
protected AbstractQueryImpl |
queryImpl
The query instance which created this query result. |
protected Name[] |
selectProps
The select properties |
protected SessionImpl |
session
The session executing the query |
protected org.apache.jackrabbit.core.query.lucene.SpellSuggestion |
spellSuggestion
The spell suggestion or null if not available. |
Constructor Summary | |
---|---|
QueryResultImpl(SearchIndex index,
ItemManager itemMgr,
SessionImpl session,
AccessManager accessMgr,
AbstractQueryImpl queryImpl,
org.apache.jackrabbit.core.query.lucene.SpellSuggestion spellSuggestion,
Name[] selectProps,
Path[] orderProps,
boolean[] orderSpecs,
boolean documentOrder,
long offset,
long limit)
Creates a new query result. |
Method Summary | |
---|---|
protected abstract ExcerptProvider |
createExcerptProvider()
Creates an excerpt provider for this result set. |
protected abstract MultiColumnQueryHits |
executeQuery(long resultFetchHint)
Executes the query for this result and returns hits. |
String[] |
getColumnNames()
|
NodeIterator |
getNodes()
|
protected void |
getResults(long size)
Attempts to get size results and puts them into resultNodes . |
RowIterator |
getRows()
|
int |
getTotalSize()
Returns the total number of hits. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final SearchIndex index
protected final ItemManager itemMgr
protected final SessionImpl session
protected final AccessManager accessMgr
protected final AbstractQueryImpl queryImpl
protected final org.apache.jackrabbit.core.query.lucene.SpellSuggestion spellSuggestion
null
if not available.
protected final Name[] selectProps
protected final Path[] orderProps
protected final boolean[] orderSpecs
protected final boolean docOrder
true
nodes are returned in document order.
Constructor Detail |
---|
public QueryResultImpl(SearchIndex index, ItemManager itemMgr, SessionImpl session, AccessManager accessMgr, AbstractQueryImpl queryImpl, org.apache.jackrabbit.core.query.lucene.SpellSuggestion spellSuggestion, Name[] selectProps, Path[] orderProps, boolean[] orderSpecs, boolean documentOrder, long offset, long limit) throws RepositoryException
getResults(long)
after this constructor had been called.
index
- the search index where the query is executed.itemMgr
- the item manager of the session executing the
query.session
- the session executing the query.accessMgr
- the access manager of the session executiong the
query.queryImpl
- the query instance which created this query
result.spellSuggestion
- the spell suggestion or null
if none
is available.selectProps
- the select properties of the query.orderProps
- the relative paths of the order properties.orderSpecs
- the order specs, one for each order property
name.documentOrder
- if true
the result is returned in
document order.limit
- the maximum result sizeoffset
- the offset in the total result set
RepositoryException
- if an error occurs while reading from the
repository.Method Detail |
---|
public String[] getColumnNames() throws RepositoryException
getColumnNames
in interface QueryResult
RepositoryException
public NodeIterator getNodes() throws RepositoryException
getNodes
in interface QueryResult
RepositoryException
public RowIterator getRows() throws RepositoryException
getRows
in interface QueryResult
RepositoryException
protected abstract MultiColumnQueryHits executeQuery(long resultFetchHint) throws IOException
resultFetchHint
- a hint on how many results should be fetched.
IOException
- if an error occurs while executing the query.protected abstract ExcerptProvider createExcerptProvider() throws IOException
IOException
- if an error occurs.protected void getResults(long size) throws RepositoryException
size
results and puts them into resultNodes
. If the size of resultNodes
is less than
size
then there are no more than resultNodes.size()
results for this query.
size
- the number of results to fetch for the query.
RepositoryException
- if an error occurs while executing the
query.public int getTotalSize()
-1
if the total size is unknown.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |