Class SimpleExpression<T>

java.lang.Object
com.querydsl.core.types.dsl.DslExpression<T>
com.querydsl.core.types.dsl.SimpleExpression<T>
Type Parameters:
T - expression type
All Implemented Interfaces:
Expression<T>, Serializable
Direct Known Subclasses:
ArrayPath, BeanPath, ComparableExpressionBase, Param, SimpleOperation, SimplePath, SimpleTemplate

public abstract class SimpleExpression<T> extends DslExpression<T>
SimpleExpression is the base class for Expression implementations.
Author:
tiwe
See Also:
  • Constructor Details

    • SimpleExpression

      public SimpleExpression(Expression<T> mixin)
  • Method Details

    • as

      public SimpleExpression<T> as(Path<T> alias)
      Create an alias for the expression
      Overrides:
      as in class DslExpression<T>
      Returns:
      alias expression
    • as

      public SimpleExpression<T> as(String alias)
      Create an alias for the expression
      Overrides:
      as in class DslExpression<T>
      Returns:
      alias expression
    • isNotNull

      public BooleanExpression isNotNull()
      Create a this is not null expression
      Returns:
      this is not null
    • isNull

      public BooleanExpression isNull()
      Create a this is null expression
      Returns:
      this is null
    • count

      public NumberExpression<Long> count()
      Get the count(this) expression
      Returns:
      count(this)
    • countDistinct

      public NumberExpression<Long> countDistinct()
      Get the count(distinct this) expression
      Returns:
      count(distinct this)
    • eq

      public BooleanExpression eq(T right)
      Create a this == right expression

      Use expr.isNull() instead of expr.eq(null)

      Parameters:
      right - rhs of the comparison
      Returns:
      this == right
    • eq

      public BooleanExpression eq(Expression<? super T> right)
      Create a this == right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this == right
    • eqAll

      public BooleanExpression eqAll(CollectionExpression<?,? super T> right)
      Create a this == all right expression
      Parameters:
      right -
      Returns:
      this == all right
    • eqAny

      public BooleanExpression eqAny(CollectionExpression<?,? super T> right)
      Create a this == < right expression
      Parameters:
      right -
      Returns:
      this == any right
    • eqAll

      public BooleanExpression eqAll(SubQueryExpression<? extends T> right)
      Create a this == all right expression
      Parameters:
      right -
      Returns:
      this == all right
    • eqAny

      public BooleanExpression eqAny(SubQueryExpression<? extends T> right)
      Create a this == any right expression
      Parameters:
      right -
      Returns:
      this == any right
    • in

      public BooleanExpression in(Collection<? extends T> right)
      Create a this in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this in right
    • in

      public BooleanExpression in(T... right)
      Create a this in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this in right
    • in

      public BooleanExpression in(CollectionExpression<?,? extends T> right)
      Create a this in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this in right
    • in

      public BooleanExpression in(SubQueryExpression<? extends T> right)
      Create a this in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this in right
    • in

      public BooleanExpression in(Expression<? extends T>... right)
      Create a this in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this in right
    • ne

      public BooleanExpression ne(T right)
      Create a this <> right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this != right
    • ne

      public BooleanExpression ne(Expression<? super T> right)
      Create a this <> right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this != right
    • neAll

      public BooleanExpression neAll(CollectionExpression<?,? super T> right)
      Create a this != all right expression
      Parameters:
      right -
      Returns:
      this != all right
    • neAny

      public BooleanExpression neAny(CollectionExpression<?,? super T> right)
      Create a this != any right expression
      Parameters:
      right -
      Returns:
      this != any right
    • notIn

      public BooleanExpression notIn(Collection<? extends T> right)
      Create a this not in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this not in right
    • notIn

      public BooleanExpression notIn(T... right)
      Create a this not in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this not in right
    • notIn

      public BooleanExpression notIn(CollectionExpression<?,? extends T> right)
      Create a this not in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this not in right
    • notIn

      public BooleanExpression notIn(SubQueryExpression<? extends T> right)
      Create a this not in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this not in right
    • notIn

      public BooleanExpression notIn(Expression<? extends T>... right)
      Create a this not in right expression
      Parameters:
      right - rhs of the comparison
      Returns:
      this not in right
    • nullif

      public SimpleExpression<T> nullif(Expression<T> other)
      Create a nullif(this, other) expression
      Parameters:
      other -
      Returns:
      nullif(this, other)
    • nullif

      public SimpleExpression<T> nullif(T other)
      Create a nullif(this, other) expression
      Parameters:
      other -
      Returns:
      nullif(this, other)
    • when

      public CaseForEqBuilder<T> when(T other)
      Create a case expression builder
      Parameters:
      other -
      Returns:
      case expression builder
    • when

      public CaseForEqBuilder<T> when(Expression<? extends T> other)
      Create a case expression builder
      Parameters:
      other -
      Returns:
      case expression builder