Class SolrJSONResultSet
java.lang.Object
org.alfresco.repo.search.impl.solr.SolrJSONResultSet
- All Implemented Interfaces:
Iterable<ResultSetRow>,SearchEngineResultMetadata,SearchEngineResultSet,ResultSet,ResultSetSPI<ResultSetRow,ResultSetMetaData>
Apache Solr
SearchEngineResultSet implementation.-
Constructor Summary
ConstructorsConstructorDescriptionSolrJSONResultSet(org.json.JSONObject json, SearchParameters searchParameters, NodeService nodeService, NodeDAO nodeDao, LimitBy limitBy, int maxResults) Detached result set based on that provided -
Method Summary
Modifier and TypeMethodDescriptionprotected List<GenericFacetResponse>buildPivot(org.json.JSONObject facet_pivot, String pivotName, List<RangeParameters> rangeParameters) buildRanges(org.json.JSONObject facet_ranges) buildStats(org.json.JSONObject statsObj) voidclose()booleanintgetChildAssocRef(int n) getFieldFacet(String field) longgetMetrics(Map<String, Object> metrics) getNodeRef(int n) longTotal number of items matching a the current query execution.booleanReturns the query execution time, or put in other words, the amount of time the search engine spent for processing the request.getRow(int i) floatgetScore(int n) intgetStart()getStats()booleanhasMore()iterator()intlength()booleansetBulkFetch(boolean bulkFetch) intsetBulkFetchSize(int bulkFetchSize) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
SolrJSONResultSet
public SolrJSONResultSet(org.json.JSONObject json, SearchParameters searchParameters, NodeService nodeService, NodeDAO nodeDao, LimitBy limitBy, int maxResults) Detached result set based on that provided- Parameters:
json- JSONObjectsearchParameters- SearchParametersnodeService- NodeServicenodeDao- NodeDAOlimitBy- LimitBymaxResults- int
-
-
Method Details
-
buildRanges
protected Map<String,List<Map<String, buildRangesString>>> (org.json.JSONObject facet_ranges) throws org.json.JSONException - Throws:
org.json.JSONException
-
buildStats
protected Map<String,Map<String, buildStatsObject>> (org.json.JSONObject statsObj) throws org.json.JSONException - Throws:
org.json.JSONException
-
buildPivot
protected List<GenericFacetResponse> buildPivot(org.json.JSONObject facet_pivot, String pivotName, List<RangeParameters> rangeParameters) throws org.json.JSONException - Throws:
org.json.JSONException
-
getMetrics
-
getNodeService
-
close
public void close()- Specified by:
closein interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getBulkFetch
public boolean getBulkFetch()- Specified by:
getBulkFetchin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getBulkFetchSize
public int getBulkFetchSize()- Specified by:
getBulkFetchSizein interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getChildAssocRef
- Specified by:
getChildAssocRefin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getChildAssocRefs
- Specified by:
getChildAssocRefsin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getNodeRef
- Specified by:
getNodeRefin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getNodeRefs
- Specified by:
getNodeRefsin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getResultSetMetaData
- Specified by:
getResultSetMetaDatain interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getRow
- Specified by:
getRowin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getScore
public float getScore(int n) - Specified by:
getScorein interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getStart
public int getStart()- Specified by:
getStartin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
hasMore
public boolean hasMore()- Specified by:
hasMorein interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
length
public int length()- Specified by:
lengthin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
setBulkFetch
public boolean setBulkFetch(boolean bulkFetch) - Specified by:
setBulkFetchin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
setBulkFetchSize
public int setBulkFetchSize(int bulkFetchSize) - Specified by:
setBulkFetchSizein interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
iterator
- Specified by:
iteratorin interfaceIterable<ResultSetRow>
-
getQueryTime
Description copied from interface:SearchEngineResultMetadataReturns the query execution time, or put in other words, the amount of time the search engine spent for processing the request.- Specified by:
getQueryTimein interfaceSearchEngineResultMetadata- Returns:
- the queryTime
-
getNumberFound
public long getNumberFound()Description copied from interface:SearchEngineResultMetadataTotal number of items matching a the current query execution.- Specified by:
getNumberFoundin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData> - Specified by:
getNumberFoundin interfaceSearchEngineResultMetadata- Returns:
- the numberFound
-
getFieldFacet
- Specified by:
getFieldFacetin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getFieldFacets
- Specified by:
getFieldFacetsin interfaceSearchEngineResultSet
-
getFacetIntervals
- Specified by:
getFacetIntervalsin interfaceSearchEngineResultSet
-
getPivotFacets
- Specified by:
getPivotFacetsin interfaceSearchEngineResultSet
-
getStats
- Specified by:
getStatsin interfaceSearchEngineResultSet
-
getLastIndexedTxId
public long getLastIndexedTxId()- Specified by:
getLastIndexedTxIdin interfaceSearchEngineResultSet
-
getFacetQueries
- Specified by:
getFacetQueriesin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getHighlighting
- Specified by:
getHighlightingin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getSpellCheckResult
- Specified by:
getSpellCheckResultin interfaceResultSetSPI<ResultSetRow,ResultSetMetaData>
-
getProcessedDenies
public boolean getProcessedDenies()- Specified by:
getProcessedDeniesin interfaceSearchEngineResultSet
-
getFacetRanges
- Specified by:
getFacetRangesin interfaceSearchEngineResultSet
-