public class Listing extends Object
| Constructor and Description |
|---|
Listing() |
| Modifier and Type | Method and Description |
|---|---|
static <T> Long |
countListing(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
Integer page,
Integer limit)
Gets the count of the found instances of the target entity
|
static <T> Long |
countListing(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
Integer page,
Integer limit,
String sortAttribute)
Gets the count of the found instances of the target entity
|
static <T> Long |
countListing(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
ListingParameters parameters)
Gets the count of the found instances of the target entity
|
static <T> List<T> |
getListing(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
Integer page,
Integer limit)
Gets the list of found instances
|
static <T> List<T> |
getListing(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
Integer page,
Integer limit,
String sortAttribute)
Gets the list of found instances
|
static <T> List<T> |
getListing(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
ListingParameters parameters)
Gets the list of found instances
|
static <T> ListingResult<T> |
getListingResult(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
Integer page,
Integer limit)
Gets the listing result
|
static <T> ListingResult<T> |
getListingResult(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
Integer page,
Integer limit,
String sortAttribute)
Gets the listing result
|
static <T> ListingResult<T> |
getListingResult(javax.persistence.EntityManager entityManager,
Class<T> entityClass,
ListingParameters parameters)
Gets the listing result
URL query parameters
filter: The filter value gets applied to every column of the table.
|
public static <T> ListingResult<T> getListingResult(javax.persistence.EntityManager entityManager, Class<T> entityClass, ListingParameters parameters)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classparameters - defines the listing queue. It contains optional query parameters as described aboveListingResult object containing metadata and the resulting list of the target entity instances (sublist in case of pagination)
Metadatapublic static <T> List<T> getListing(javax.persistence.EntityManager entityManager, Class<T> entityClass, ListingParameters parameters)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classparameters - defines the listing queue. It contains optional query parameters as described abovepublic static <T> Long countListing(javax.persistence.EntityManager entityManager, Class<T> entityClass, ListingParameters parameters)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classparameters - defines the listing queue. It contains optional query parameters as described abovepublic static <T> ListingResult<T> getListingResult(javax.persistence.EntityManager entityManager, Class<T> entityClass, Integer page, Integer limit)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classpage - Current page (pagination)limit - Amount of given result for the current page, see list results (pagination, if 0 then there is no limit)ListingResult object containing metadata and the resulting list of the target entity instances (sublist in case of pagination)public static <T> List<T> getListing(javax.persistence.EntityManager entityManager, Class<T> entityClass, Integer page, Integer limit)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classpage - Current page (pagination)limit - Amount of given result for the current page, see list results (pagination, if 0 then there is no limit)public static <T> Long countListing(javax.persistence.EntityManager entityManager, Class<T> entityClass, Integer page, Integer limit)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classpage - Current page (pagination)limit - Amount of given result for the current page, see list results (pagination, if 0 then there is no limit)public static <T> ListingResult<T> getListingResult(javax.persistence.EntityManager entityManager, Class<T> entityClass, Integer page, Integer limit, String sortAttribute)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classpage - Current page (pagination)limit - Amount of given result for the current page, see list results (pagination, if 0 then there is no limit)sortAttribute - Current order by this row (ascending except if it starts with "-" = descending)ListingResult object containing metadata and the resulting list of the target entity instances (sublist in case of pagination)public static <T> List<T> getListing(javax.persistence.EntityManager entityManager, Class<T> entityClass, Integer page, Integer limit, String sortAttribute)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classpage - Current page (pagination)limit - Amount of given result for the current page, see list results (pagination, if 0 then there is no limit)sortAttribute - Current order by this row (ascending except if it starts with "-" = descending)public static <T> Long countListing(javax.persistence.EntityManager entityManager, Class<T> entityClass, Integer page, Integer limit, String sortAttribute)
T - type of target entity classentityManager - entity manager of designated persistence unitentityClass - target entity classpage - Current page (pagination)limit - Amount of given result for the current page, see list results (pagination, if 0 then there is no limit)sortAttribute - Current order by this row (ascending except if it starts with "-" = descending)Copyright © 2017–2019 coodoo GmbH. All rights reserved.