Class DaoPagedResultFactory


  • public class DaoPagedResultFactory
    extends Object
    Factory for creating PagedResults for DAO queries.
    Since:
    8.2.0
    Author:
    XIMA MEDIA GmbH
    • Method Detail

      • forQuery

        public static <TEntity extends ITransferableEntity,​TQuery extends de.xima.cmn.criteria.interfaces.IFilterableCriteriaManager & de.xima.cmn.criteria.interfaces.ISortableCriteriaManager & de.xima.cmn.criteria.interfaces.IPageableCriteriaManager> PagedResult<TEntity> forQuery​(IEntityContext ec,
                                                                                                                                                                                                                                                                                                IGenericDao<TEntity> dao,
                                                                                                                                                                                                                                                                                                TQuery query)
        Gets a pagedd result for the given query
        Type Parameters:
        TEntity - type of the entities to get as part of the paged result.
        TQuery - type of the query. Usually this is a QueryCriteriaManager.
        Parameters:
        ec - entity context for database transactions.
        dao - to use for resolving the query.
        query - to resolve as a paged result.
        Returns:
        the paged result for the given query.