Module org.eclipse.persistence.core
Class ExpressionMath
java.lang.Object
org.eclipse.persistence.expressions.ExpressionMath
Purpose: This class mirrors the java.lang.Math class to allow mathimetical function support within expressions.
Example:
ExpressionBuilder builder = new ExpressionBuilder(); Expression poorAndRich = ExpressionMath.abs(builder.get("netWorth")).greaterThan(1000000); session.readAllObjects(Company.class, poorAndRich);
-
Method Summary
Modifier and TypeMethodDescriptionstatic Expression
abs
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
acos
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
add
(Expression left, int right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
add
(Expression right, Object left) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
asin
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
atan
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
atan2
(Expression expression, int value) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
atan2
(Expression expression, Object value) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
atan2
(Expression expression1, Expression expression2) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
ceil
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
chr
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
cos
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
cosh
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
cot
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
divide
(Expression left, int right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
divide
(Expression left, Object right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
exp
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
floor
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static ExpressionOperator
getOperator
(int selector) INTERNAL: Return the operator.static Expression
ln
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
log
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
max
(Expression left, int right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
max
(Expression left, Object right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
min
(Expression left, int right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
min
(Expression left, Object right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
mod
(Expression expression, int base) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
mod
(Expression expression, Object base) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
multiply
(Expression left, int right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
multiply
(Expression left, Object right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
negate
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
power
(Expression expression, int raised) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
power
(Expression expression, Object raised) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
round
(Expression expression, int decimalPlaces) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
round
(Expression expression, Object decimalPlaces) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
sign
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
sin
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
sinh
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
sqrt
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
subtract
(Expression left, int right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
subtract
(Expression left, Object right) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
tan
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
tanh
(Expression expression) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
trunc
(Expression expression, int decimalPlaces) PUBLIC: Return a new expression that applies the function to the given expression.static Expression
trunc
(Expression expression, Object decimalPlaces) PUBLIC: Return a new expression that applies the function to the given expression.
-
Method Details
-
abs
PUBLIC: Return a new expression that applies the function to the given expression.Example:
Example: ExpressionMath.abs(builder.get("netWorth")).greaterThan(1000000);
-
acos
PUBLIC: Return a new expression that applies the function to the given expression. -
add
PUBLIC: Return a new expression that applies the function to the given expression. -
add
PUBLIC: Return a new expression that applies the function to the given expression. -
asin
PUBLIC: Return a new expression that applies the function to the given expression. -
atan
PUBLIC: Return a new expression that applies the function to the given expression. -
atan2
PUBLIC: Return a new expression that applies the function to the given expression. -
atan2
PUBLIC: Return a new expression that applies the function to the given expression. -
atan2
PUBLIC: Return a new expression that applies the function to the given expression. -
ceil
PUBLIC: Return a new expression that applies the function to the given expression. -
chr
PUBLIC: Return a new expression that applies the function to the given expression. -
cos
PUBLIC: Return a new expression that applies the function to the given expression. -
cosh
PUBLIC: Return a new expression that applies the function to the given expression. -
cot
PUBLIC: Return a new expression that applies the function to the given expression. -
divide
PUBLIC: Return a new expression that applies the function to the given expression. -
divide
PUBLIC: Return a new expression that applies the function to the given expression. -
exp
PUBLIC: Return a new expression that applies the function to the given expression. -
floor
PUBLIC: Return a new expression that applies the function to the given expression. -
getOperator
INTERNAL: Return the operator. -
ln
PUBLIC: Return a new expression that applies the function to the given expression. -
log
PUBLIC: Return a new expression that applies the function to the given expression. -
max
PUBLIC: Return a new expression that applies the function to the given expression. -
max
PUBLIC: Return a new expression that applies the function to the given expression. -
min
PUBLIC: Return a new expression that applies the function to the given expression. -
min
PUBLIC: Return a new expression that applies the function to the given expression. -
mod
PUBLIC: Return a new expression that applies the function to the given expression. -
mod
PUBLIC: Return a new expression that applies the function to the given expression. -
multiply
PUBLIC: Return a new expression that applies the function to the given expression. -
multiply
PUBLIC: Return a new expression that applies the function to the given expression. -
negate
PUBLIC: Return a new expression that applies the function to the given expression. -
power
PUBLIC: Return a new expression that applies the function to the given expression. -
power
PUBLIC: Return a new expression that applies the function to the given expression. -
round
PUBLIC: Return a new expression that applies the function to the given expression. -
round
PUBLIC: Return a new expression that applies the function to the given expression. -
sign
PUBLIC: Return a new expression that applies the function to the given expression. -
sin
PUBLIC: Return a new expression that applies the function to the given expression. -
sinh
PUBLIC: Return a new expression that applies the function to the given expression. -
sqrt
PUBLIC: Return a new expression that applies the function to the given expression. -
subtract
PUBLIC: Return a new expression that applies the function to the given expression. -
subtract
PUBLIC: Return a new expression that applies the function to the given expression. -
tan
PUBLIC: Return a new expression that applies the function to the given expression. -
tanh
PUBLIC: Return a new expression that applies the function to the given expression. -
trunc
PUBLIC: Return a new expression that applies the function to the given expression. -
trunc
PUBLIC: Return a new expression that applies the function to the given expression.
-