H - The type of query hits.public interface SearchFetchable<H>
| Modifier and Type | Method and Description |
|---|---|
SearchResult<H> |
fetch()
Execute the query and return the
SearchResult. |
SearchResult<H> |
fetch(Integer limit)
Execute the query and return the
SearchResult. |
SearchResult<H> |
fetch(Integer limit,
Integer offset)
Execute the query and return the
SearchResult. |
List<H> |
fetchHits()
Execute the query and return the hits as a
List. |
List<H> |
fetchHits(Integer limit)
Execute the query and return the hits as a
List. |
List<H> |
fetchHits(Integer limit,
Integer offset)
Execute the query and return the hits as a
List. |
Optional<H> |
fetchSingleHit()
Execute the query and return the hits as a single, optional element.
|
long |
fetchTotalHitCount()
Execute the query and return the total hit count.
|
SearchResult<H> fetch()
SearchResult.SearchResult.SearchException - If something goes wrong while executing the query.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.SearchResult<H> fetch(Integer limit)
SearchResult.limit - The maximum number of hits to be included in the SearchResult. null means no limit.SearchResult.SearchException - If something goes wrong while executing the query.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.SearchResult<H> fetch(Integer limit, Integer offset)
SearchResult.limit - The maximum number of hits to be included in the SearchResult. null means no limit.offset - The number of hits to skip before adding the hits to the SearchResult. null means no offset.SearchResult.SearchException - If something goes wrong while executing the query.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.List<H> fetchHits()
List.SearchException - If something goes wrong while executing the query.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.List<H> fetchHits(Integer limit)
List.limit - The maximum number of hits to be returned by this method. null means no limit.SearchException - If something goes wrong while executing the query.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.List<H> fetchHits(Integer limit, Integer offset)
List.limit - The maximum number of hits to be returned by this method. null means no limit.offset - The number of hits to skip. null means no offset.SearchException - If something goes wrong while executing the query.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.Optional<H> fetchSingleHit()
SearchException - If something goes wrong while executing the query,
or the number of hits is more than one.RuntimeException - If something goes wrong while loading entities. The exact type depends on the mapper,
e.g. HibernateException/PersistenceException for the Hibernate ORM mapper.long fetchTotalHitCount()
SearchException - If something goes wrong while executing the query.Copyright © 2006-2019 Red Hat, Inc. and others. Licensed under the GNU Lesser General Public License (LGPL), version 2.1 or later.