Package com.day.cq.wcm.foundation
Class Search.Result
java.lang.Object
com.day.cq.wcm.foundation.Search.Result
- Enclosing class:
Search
A search result.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the execution time in fractions of a second.longReturns the execution time in milliseconds.Returns the facets for this search result.getHits()longlong
-
Method Details
-
getResultPages
- Returns:
- a List of
Search.Pagees to display the navigation through the result pages. - Throws:
RepositoryException- if an error occurs while reading from the query result.
-
getPreviousPage
- Returns:
- the page, which contains the information about the previous page.
Returns
nullif there is no previous page (i.e. the current page is the first page). - Throws:
RepositoryException- if an error occurs while reading from the query result.
-
getNextPage
- Returns:
- the page, which contains the information about the next page.
Returns
nullif there is no next page (i.e. the current page is the last page). - Throws:
RepositoryException- if an error occurs while reading from the query result.
-
getTrackerScript
- Returns:
- the script for query and result tracking.
-
getSpellcheck
- Returns:
- the result of a spell check or
nullif spell checking is not supported or the repository thinks the spelling is correct.
-
getStartIndex
public long getStartIndex()- Returns:
- the start index. i.e. from where to start to display the hits.
-
getTotalMatches
public long getTotalMatches()- Returns:
- the total number of matches.
-
getExecutionTime
Returns the execution time in fractions of a second. Example: 0.08 (means, the query took 80 milliseconds to execute).- Returns:
- the execution time of the query.
-
getExecutionTimeMillis
public long getExecutionTimeMillis()Returns the execution time in milliseconds.- Returns:
- the execution time of the query.
-
getFacets
Returns the facets for this search result.- Returns:
- the facets for this search result.
- Throws:
RepositoryException- if an error occurs while executing the query or calculating the facets.
-
getHits
- Returns:
- a List of
Search.Hits to display on the result page.
-