T
- expression typepublic abstract class NumberExpression<T extends java.lang.Number & java.lang.Comparable<?>> extends ComparableExpressionBase<T>
NumberExpression
represents a numeric expressionNumber
,
Serialized FormhashCode, mixin
Constructor and Description |
---|
NumberExpression(Expression<T> mixin) |
Modifier and Type | Method and Description |
---|---|
NumberExpression<T> |
abs()
Create a
abs(this) expression |
<N extends java.lang.Number & java.lang.Comparable<?>> |
add(Expression<N> right)
Create a
this + right expression |
<N extends java.lang.Number & java.lang.Comparable<N>> |
add(N right)
Create a
this + right expression |
NumberExpression<T> |
as(Path<T> alias)
Create an alias for the expression
|
NumberExpression<T> |
as(java.lang.String alias)
Create an alias for the expression
|
NumberExpression<java.lang.Double> |
avg()
Create a
avg(this) expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
between(A from,
A to)
Create a
this between from and to expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
between(@Nullable Expression<A> from,
@Nullable Expression<A> to)
Create a
this between from and to expression |
NumberExpression<java.lang.Byte> |
byteValue()
Create a
cast(this as byte) expression |
<A extends java.lang.Number & java.lang.Comparable<? super A>> |
castToNum(java.lang.Class<A> type) |
NumberExpression<T> |
ceil()
Create a
ceil(this) expression |
NumberExpression<T> |
coalesce(Expression<?>... exprs)
Create a
coalesce(this, exprs...) expression |
NumberExpression<T> |
coalesce(Expression<T> expr)
Create a
coalesce(this, expr) expression |
NumberExpression<T> |
coalesce(T... args)
Create a
coalesce(this, args...) expression |
NumberExpression<T> |
coalesce(T arg)
Create a
coalesce(this, arg) expression |
<N extends java.lang.Number & java.lang.Comparable<?>> |
divide(Expression<N> right)
Create a
this / right expression |
<N extends java.lang.Number & java.lang.Comparable<?>> |
divide(N right)
Create a
this / right expression |
NumberExpression<java.lang.Double> |
doubleValue()
Create a
cast(this as double) expression |
NumberExpression<java.lang.Float> |
floatValue()
Create a
cast(this as double) expression |
NumberExpression<T> |
floor()
Create a
floor(this) expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
goe(A right)
Create a
this >= right expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
goe(Expression<A> right)
Create a
this >= right expression |
BooleanExpression |
goeAll(CollectionExpression<?,? super T> right)
Create a
this >= all right expression |
BooleanExpression |
goeAny(CollectionExpression<?,? super T> right)
Create a
this >= any right expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
gt(A right)
Create a
this > right expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
gt(Expression<A> right)
Create a
this > right expression |
BooleanExpression |
gtAll(CollectionExpression<?,? super T> right)
Create a
this > all right expression |
BooleanExpression |
gtAll(SubQueryExpression<? extends T> right)
Create a
this > all right expression |
BooleanExpression |
gtAny(CollectionExpression<?,? super T> right)
Create a
this > any right expression |
BooleanExpression |
gtAny(SubQueryExpression<? extends T> right)
Create a
this > any right expression |
BooleanExpression |
in(java.lang.Number... numbers)
Create a
this in right expression |
NumberExpression<java.lang.Integer> |
intValue()
Create a
this.intValue() expression |
BooleanExpression |
like(Expression<java.lang.String> str)
Create a
this like str expression |
BooleanExpression |
like(java.lang.String str)
Create a
this like str expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
loe(A right)
Create a
this <= right expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
loe(Expression<A> right)
Create a
this <= right expression |
BooleanExpression |
loeAll(CollectionExpression<?,? super T> right)
Create a
this <= all right expression |
BooleanExpression |
loeAny(CollectionExpression<?,? super T> right)
Create a
this <= any right expression |
NumberExpression<java.lang.Long> |
longValue()
Create a
this.longValue() expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
lt(A right)
Create a
this < right expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
lt(Expression<A> right)
Create a
this < right expression |
BooleanExpression |
ltAll(CollectionExpression<?,? super T> right)
Create a
this < all right expression |
BooleanExpression |
ltAny(CollectionExpression<?,? super T> right)
Create a
this < any right expression |
NumberExpression<T> |
max()
Create a
max(this) expression |
static <A extends java.lang.Number & java.lang.Comparable<?>> |
max(Expression<A> left,
Expression<A> right)
Create a
max(left, right) expression |
NumberExpression<T> |
min()
Create a
min(this) expression |
static <A extends java.lang.Number & java.lang.Comparable<?>> |
min(Expression<A> left,
Expression<A> right)
Create a
min(left, right) expression |
NumberExpression<T> |
mod(Expression<T> num)
Create a
mod(this, num) expression |
NumberExpression<T> |
mod(T num)
Create a
mod(this, num) expression |
<N extends java.lang.Number & java.lang.Comparable<?>> |
multiply(Expression<N> right)
Create a
this * right expression |
<N extends java.lang.Number & java.lang.Comparable<N>> |
multiply(N right)
Create a
this * right expression |
NumberExpression<T> |
negate()
Create a
this * -1 expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
notBetween(A from,
A to)
Create a
this not between from and to expression |
<A extends java.lang.Number & java.lang.Comparable<?>> |
notBetween(Expression<A> from,
Expression<A> to)
Create a
this not between from and to expression |
BooleanExpression |
notIn(java.lang.Number... numbers)
Create a
this not in right expression |
NumberExpression<T> |
nullif(Expression<T> other)
Create a
nullif(this, other) expression |
NumberExpression<T> |
nullif(T other)
Create a
nullif(this, other) expression |
static NumberExpression<java.lang.Double> |
random()
Create a
random() expression |
NumberExpression<T> |
round()
Create a
round(this) expression |
NumberExpression<java.lang.Short> |
shortValue()
Create a
this.shortValue() expression |
NumberExpression<java.lang.Double> |
sqrt()
Create a
sqrt(this) expression |
StringExpression |
stringValue()
Create a cast to String expression
|
<N extends java.lang.Number & java.lang.Comparable<?>> |
subtract(Expression<N> right)
Create a
this - right expression |
<N extends java.lang.Number & java.lang.Comparable<?>> |
subtract(N right)
Create a
this - right expression |
NumberExpression<T> |
sum()
Create a
sum(this) expression |
asc, desc
count, countDistinct, eq, eq, eqAll, eqAll, eqAny, eqAny, in, in, in, in, isNotNull, isNull, ne, ne, neAll, neAny, notIn, notIn, notIn, notIn, when, when
equals, getType, hashCode, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
accept
public NumberExpression(Expression<T> mixin)
public static <A extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<A> max(Expression<A> left, Expression<A> right)
max(left, right)
expression
Return the greater of the given values
public static <A extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<A> min(Expression<A> left, Expression<A> right)
min(left, right)
expression
Returns the smaller of the given values
public static NumberExpression<java.lang.Double> random()
random()
expression
Returns the random number
public NumberExpression<T> as(Path<T> alias)
SimpleExpression
as
in class SimpleExpression<T extends java.lang.Number & java.lang.Comparable<?>>
public NumberExpression<T> as(java.lang.String alias)
SimpleExpression
as
in class SimpleExpression<T extends java.lang.Number & java.lang.Comparable<?>>
public StringExpression stringValue()
Object.toString()
public NumberExpression<T> abs()
abs(this)
expression
Returns the absolute value of this expression
public <N extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<T> add(Expression<N> right)
this + right
expression
Returns the sum of this and right
right
- rhs of expressionpublic <N extends java.lang.Number & java.lang.Comparable<N>> NumberExpression<T> add(N right)
this + right
expression
Get the sum of this and right
right
- rhs of expressionpublic NumberExpression<java.lang.Double> avg()
avg(this)
expression
Get the average value of this expression (aggregation)
public NumberExpression<java.lang.Byte> byteValue()
cast(this as byte)
expression
Get the byte expression of this numeric expression
Number.byteValue()
public <A extends java.lang.Number & java.lang.Comparable<? super A>> NumberExpression<A> castToNum(java.lang.Class<A> type)
public NumberExpression<T> ceil()
ceil(this)
expression
Returns the smallest (closest to negative infinity)
double
value that is greater than or equal to the
argument and is equal to a mathematical integer
Math.ceil(double)
public <N extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<T> divide(Expression<N> right)
this / right
expression
Get the result of the operation this / right
right
- public <N extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<T> divide(N right)
this / right
expression
Get the result of the operation this / right
right
- public NumberExpression<java.lang.Double> doubleValue()
cast(this as double)
expression
Get the double expression of this numeric expression
Number.doubleValue()
public NumberExpression<java.lang.Float> floatValue()
cast(this as double)
expression
Get the float expression of this numeric expression
Number.floatValue()
public NumberExpression<T> floor()
floor(this)
expression
Returns the largest (closest to positive infinity)
double
value that is less than or equal to the
argument and is equal to a mathematical integer.
Math.floor(double)
public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression goe(A right)
this >= right
expressionA
- right
- rhs of the comparisonthis >= right
Comparable.compareTo(Object)
public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression goe(Expression<A> right)
this >= right
expressionA
- right
- rhs of the comparisonthis >= right
Comparable.compareTo(Object)
public BooleanExpression goeAll(CollectionExpression<?,? super T> right)
this >= all right
expressionright
- public BooleanExpression goeAny(CollectionExpression<?,? super T> right)
this >= any right
expressionright
- public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression gt(A right)
this > right
expressionA
- right
- rhs of the comparisonthis > right
Comparable.compareTo(Object)
public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression gt(Expression<A> right)
this > right
expressionA
- right
- rhs of the comparisonthis > right
Comparable.compareTo(Object)
public BooleanExpression gtAll(CollectionExpression<?,? super T> right)
this > all right
expressionright
- public BooleanExpression gtAny(CollectionExpression<?,? super T> right)
this > any right
expressionright
- public BooleanExpression gtAll(SubQueryExpression<? extends T> right)
this > all right
expressionright
- public BooleanExpression gtAny(SubQueryExpression<? extends T> right)
this > any right
expressionright
- public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression between(@Nullable A from, @Nullable A to)
this between from and to
expression
Is equivalent to from <= this <= to
A
- from
- inclusive start of rangeto
- inclusive end of rangepublic final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression between(@Nullable @Nullable Expression<A> from, @Nullable @Nullable Expression<A> to)
this between from and to
expression
Is equivalent to from <= this <= to
A
- from
- inclusive start of rangeto
- inclusive end of rangepublic final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression notBetween(A from, A to)
this not between from and to
expression
Is equivalent to this < from || this > to
from
- inclusive start of rangeto
- inclusive end of rangepublic final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression notBetween(Expression<A> from, Expression<A> to)
this not between from and to
expression
Is equivalent to this < from || this > to
from
- inclusive start of rangeto
- inclusive end of rangepublic NumberExpression<java.lang.Integer> intValue()
this.intValue()
expression
Get the int expression of this numeric expression
Number.intValue()
public BooleanExpression like(java.lang.String str)
this like str
expressionstr
- rhspublic BooleanExpression like(Expression<java.lang.String> str)
this like str
expressionstr
- public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression loe(A right)
this <= right
expressionA
- right
- rhs of the comparisonthis <= right
Comparable.compareTo(Object)
public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression loe(Expression<A> right)
this <= right
expressionA
- right
- rhs of the comparisonthis <= right
Comparable.compareTo(Object)
public BooleanExpression loeAll(CollectionExpression<?,? super T> right)
this <= all right
expressionright
- rhspublic BooleanExpression loeAny(CollectionExpression<?,? super T> right)
this <= any right
expressionright
- rhspublic NumberExpression<java.lang.Long> longValue()
this.longValue()
expression
Get the long expression of this numeric expression
Number.longValue()
public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression lt(A right)
this < right
expressionA
- right
- rhs of the comparisonthis < right
Comparable.compareTo(Object)
public final <A extends java.lang.Number & java.lang.Comparable<?>> BooleanExpression lt(Expression<A> right)
this < right
expressionA
- right
- rhs of the comparisonthis < right
Comparable.compareTo(Object)
public BooleanExpression ltAll(CollectionExpression<?,? super T> right)
this < all right
expressionright
- rhspublic BooleanExpression ltAny(CollectionExpression<?,? super T> right)
this < any right
expressionright
- rhspublic NumberExpression<T> max()
max(this)
expression
Get the maximum value of this expression (aggregation)
max
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
public NumberExpression<T> min()
min(this)
expression
Get the minimum value of this expression (aggregation)
min
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
public NumberExpression<T> mod(Expression<T> num)
mod(this, num)
expressionnum
- public NumberExpression<T> mod(T num)
mod(this, num)
expressionnum
- public <N extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<T> multiply(Expression<N> right)
this * right
expression
Get the result of the operation this * right
right
- public <N extends java.lang.Number & java.lang.Comparable<N>> NumberExpression<T> multiply(N right)
this * right
expression
Get the result of the operation this * right
right
- public NumberExpression<T> negate()
this * -1
expression
Get the negation of this expression
public NumberExpression<T> round()
round(this)
expression
Returns the closest int
to this.
Math.round(double)
,
Math.round(float)
public NumberExpression<java.lang.Short> shortValue()
this.shortValue()
expression
Get the short expression of this numeric expression
Number.shortValue()
public NumberExpression<java.lang.Double> sqrt()
sqrt(this)
expression
Get the square root of this numeric expressions
public <N extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<T> subtract(Expression<N> right)
this - right
expression
Get the difference of this and right
right
- public <N extends java.lang.Number & java.lang.Comparable<?>> NumberExpression<T> subtract(N right)
this - right
expression
Get the difference of this and right
right
- public NumberExpression<T> sum()
sum(this)
expression
Get the sum of this expression (aggregation)
public BooleanExpression in(java.lang.Number... numbers)
SimpleExpression
this in right
expressionin
in class SimpleExpression<T extends java.lang.Number & java.lang.Comparable<?>>
numbers
- rhs of the comparisonpublic BooleanExpression notIn(java.lang.Number... numbers)
SimpleExpression
this not in right
expressionnotIn
in class SimpleExpression<T extends java.lang.Number & java.lang.Comparable<?>>
numbers
- rhs of the comparisonpublic NumberExpression<T> nullif(Expression<T> other)
nullif(this, other)
expressionnullif
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
other
- public NumberExpression<T> nullif(T other)
nullif(this, other)
expressionnullif
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
other
- public NumberExpression<T> coalesce(Expression<T> expr)
coalesce(this, expr)
expressioncoalesce
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
expr
- additional argumentpublic NumberExpression<T> coalesce(Expression<?>... exprs)
coalesce(this, exprs...)
expressioncoalesce
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
exprs
- additional argumentspublic NumberExpression<T> coalesce(T arg)
coalesce(this, arg)
expressioncoalesce
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
arg
- additional argumentpublic NumberExpression<T> coalesce(T... args)
coalesce(this, args...)
expressioncoalesce
in class ComparableExpressionBase<T extends java.lang.Number & java.lang.Comparable<?>>
args
- additional argumentsCopyright © 2007–2021 Querydsl. All rights reserved.