Class SimpleSearchResult<H>
java.lang.Object
org.hibernate.search.engine.search.query.spi.SimpleSearchResult<H>
- All Implemented Interfaces:
SearchResult<H>
-
Constructor Summary
ConstructorsConstructorDescriptionSimpleSearchResult(SearchResultTotal resultTotal, List<H> hits, Map<AggregationKey<?>, ?> aggregationResults, Duration took, Boolean timedOut) -
Method Summary
Modifier and TypeMethodDescription<T> Taggregation(AggregationKey<T> key) hits()booleantimedOut()took()toString()total()
-
Constructor Details
-
SimpleSearchResult
public SimpleSearchResult(SearchResultTotal resultTotal, List<H> hits, Map<AggregationKey<?>, ?> aggregationResults, Duration took, Boolean timedOut)
-
-
Method Details
-
total
- Specified by:
totalin interfaceSearchResult<H>- Returns:
- The total for a search result, pertaining to all matched documents, independently from the offset/limit used when fetching hits. Includes in particular the total hit count.
-
hits
- Specified by:
hitsin interfaceSearchResult<H>- Returns:
- The hits as a
Listcontaining one element for each matched entity.
-
aggregation
- Specified by:
aggregationin interfaceSearchResult<H>- Type Parameters:
T- The type of result for this aggregation.- Parameters:
key- The key previously used to register the aggregation during query building.- Returns:
- The result for the given aggregation.
-
took
- Specified by:
tookin interfaceSearchResult<H>- Returns:
- the time taken to process the request, as a
Duration
-
timedOut
public boolean timedOut()- Specified by:
timedOutin interfaceSearchResult<H>- Returns:
- whether or not a timeout occurred processing the request.
-
toString
-