Interface ExtendedQueryResult<E>

Type Parameters:
E - Entity type.
All Superinterfaces:
org.apache.deltaspike.data.api.QueryResult<E>

public interface ExtendedQueryResult<E> extends org.apache.deltaspike.data.api.QueryResult<E>
An extended version of QueryResult that allows to configure Blaze-Persistence specific features.
Since:
1.2.0
Author:
Christian Beikov
  • Method Details

    • getPageResultList

      List<E> getPageResultList()
      Returns the result list of the page for which this query was constructed for without executing a count query.
      Returns:
      The result list of the requested page
    • getResultList

      List<E> getResultList()
      If paginated, returns a PagedList containing the result list of the requested page and optionally the total count depending on withCountQuery(boolean). Otherwise, returns a List.
      Specified by:
      getResultList in interface org.apache.deltaspike.data.api.QueryResult<E>
      Returns:
      The result as PagedList if paginated or List otherwise
    • withCountQuery

      ExtendedQueryResult<E> withCountQuery(boolean withCountQuery)
      Enables or disables the execution of the count query which determines whether PagedList.getTotalSize() is available.
      Parameters:
      withCountQuery - true to enable, false to disable the count query execution
      Returns:
      The query result for chaining calls
    • orderAsc

      <X> ExtendedQueryResult<E> orderAsc(javax.persistence.metamodel.SingularAttribute<E,X> attribute)
      Specified by:
      orderAsc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderAsc

      <X> ExtendedQueryResult<E> orderAsc(javax.persistence.metamodel.SingularAttribute<E,X> attribute, boolean appendEntityName)
      Specified by:
      orderAsc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderAsc

      ExtendedQueryResult<E> orderAsc(String attribute)
      Specified by:
      orderAsc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderAsc

      ExtendedQueryResult<E> orderAsc(String attribute, boolean appendEntityName)
      Specified by:
      orderAsc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderDesc

      <X> ExtendedQueryResult<E> orderDesc(javax.persistence.metamodel.SingularAttribute<E,X> attribute)
      Specified by:
      orderDesc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderDesc

      <X> ExtendedQueryResult<E> orderDesc(javax.persistence.metamodel.SingularAttribute<E,X> attribute, boolean appendEntityName)
      Specified by:
      orderDesc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderDesc

      ExtendedQueryResult<E> orderDesc(String attribute)
      Specified by:
      orderDesc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • orderDesc

      ExtendedQueryResult<E> orderDesc(String attribute, boolean appendEntityName)
      Specified by:
      orderDesc in interface org.apache.deltaspike.data.api.QueryResult<E>
    • changeOrder

      <X> ExtendedQueryResult<E> changeOrder(javax.persistence.metamodel.SingularAttribute<E,X> attribute)
      Specified by:
      changeOrder in interface org.apache.deltaspike.data.api.QueryResult<E>
    • clearOrder

      ExtendedQueryResult<E> clearOrder()
      Specified by:
      clearOrder in interface org.apache.deltaspike.data.api.QueryResult<E>
    • changeOrder

      ExtendedQueryResult<E> changeOrder(String attribute)
      Specified by:
      changeOrder in interface org.apache.deltaspike.data.api.QueryResult<E>
    • maxResults

      ExtendedQueryResult<E> maxResults(int max)
      Specified by:
      maxResults in interface org.apache.deltaspike.data.api.QueryResult<E>
    • firstResult

      ExtendedQueryResult<E> firstResult(int first)
      Specified by:
      firstResult in interface org.apache.deltaspike.data.api.QueryResult<E>
    • lockMode

      ExtendedQueryResult<E> lockMode(javax.persistence.LockModeType lockMode)
      Specified by:
      lockMode in interface org.apache.deltaspike.data.api.QueryResult<E>
    • flushMode

      ExtendedQueryResult<E> flushMode(javax.persistence.FlushModeType flushMode)
      Specified by:
      flushMode in interface org.apache.deltaspike.data.api.QueryResult<E>
    • hint

      ExtendedQueryResult<E> hint(String hint, Object value)
      Specified by:
      hint in interface org.apache.deltaspike.data.api.QueryResult<E>
    • withPageSize

      ExtendedQueryResult<E> withPageSize(int pageSize)
      Specified by:
      withPageSize in interface org.apache.deltaspike.data.api.QueryResult<E>
    • toPage

      ExtendedQueryResult<E> toPage(int page)
      Specified by:
      toPage in interface org.apache.deltaspike.data.api.QueryResult<E>
    • nextPage

      ExtendedQueryResult<E> nextPage()
      Specified by:
      nextPage in interface org.apache.deltaspike.data.api.QueryResult<E>
    • previousPage

      ExtendedQueryResult<E> previousPage()
      Specified by:
      previousPage in interface org.apache.deltaspike.data.api.QueryResult<E>