Class QueryBase<Q extends QueryBase<Q>>

java.lang.Object
com.querydsl.core.support.QueryBase<Q>
Type Parameters:
Q - concrete subtype
Direct Known Subclasses:
FetchableQueryBase

public abstract class QueryBase<Q extends QueryBase<Q>> extends Object
QueryBase provides a stub for Query implementations
Author:
tiwe
  • Field Details

  • Constructor Details

    • QueryBase

      public QueryBase(QueryMixin<Q> queryMixin)
  • Method Details

    • distinct

      public Q distinct()
      Set the Query to return distinct results
      Returns:
      the current object
    • groupBy

      public Q groupBy(Expression<?> e)
      Add a single grouping expression
      Parameters:
      e - group by expression
      Returns:
      the current object
    • groupBy

      public Q groupBy(Expression<?>... o)
      Add grouping/aggregation expressions
      Parameters:
      o - group by expressions
      Returns:
      the current object
    • having

      public Q having(Predicate e)
      Add a single filter for aggregation
      Parameters:
      e - having condition
      Returns:
      the current object
    • having

      public Q having(Predicate... o)
      Add filters for aggregation
      Parameters:
      o - having conditions
      Returns:
      the current object
    • orderBy

      public Q orderBy(OrderSpecifier<?> o)
      Add a single order expression
      Parameters:
      o - order
      Returns:
      the current object
    • orderBy

      public Q orderBy(OrderSpecifier<?>... o)
      Add order expressions
      Parameters:
      o - order
      Returns:
      the current object
    • where

      public Q where(Predicate o)
      Add the given filter condition

      Skips null arguments

      Parameters:
      o - filter conditions to be added
      Returns:
      the current object
    • where

      public Q where(Predicate... o)
      Add the given filter conditions

      Skips null arguments

      Parameters:
      o - filter conditions to be added
      Returns:
      the current object
    • limit

      public Q limit(@org.jetbrains.annotations.Range(from=0L, to=2147483647L) long limit)
      Defines the limit / max results for the query results
      Parameters:
      limit - max rows
      Returns:
      the current object
    • offset

      public Q offset(long offset)
      Defines the offset for the query results
      Parameters:
      offset - row offset
      Returns:
      the current object
    • restrict

      public Q restrict(QueryModifiers modifiers)
      Defines both limit and offset of the query results, use QueryModifiers.EMPTY to apply no paging.
      Parameters:
      modifiers - query modifiers
      Returns:
      the current object
    • set

      public <P> Q set(ParamExpression<P> param, P value)
      Set the given parameter to the given value
      Type Parameters:
      P -
      Parameters:
      param - param
      value - binding
      Returns:
      the current object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object