313233343536373839
* @param args Single numeric value * @return Absolute value */ public Value execute(Value... args) { Value arg = args[0]; return literalConstant(abs(arg.asNumber()), arg); } }
3233343536373839
* @return Smallest of these */ public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(min(left.asNumber(), right.asNumber()), left, right); } }
323334353637383940
* @return Largest of these */ public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(max(left.asNumber(), right.asNumber()), left, right); } }
262728293031323334
public class LessOrEqualFunction extends NonEscapingFunction { public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(left.asNumber() <= right.asNumber(), left, right); } }
public class NumericNotEqualFunction extends NonEscapingFunction { public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(left.asNumber() != right.asNumber(), left, right); } }
public class NumericEqualFunction extends NonEscapingFunction { public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(left.asNumber() == right.asNumber(), left, right); } }
public class MultiplyFunction extends NonEscapingFunction { public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(left.asNumber() * right.asNumber(), left, right); } }
public class GreaterFunction extends NonEscapingFunction { public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(left.asNumber() > right.asNumber(), left, right); } }
252627282930313233
*/ public class NumericFunction extends NonEscapingFunction { public Value execute(Value... args) { Value value = args[0]; return literalConstant(value.asNumber(), value); } }
public class GreaterOrEqualFunction extends NonEscapingFunction { public Value execute(Value... args) { Value left = args[0]; Value right = args[1]; return literalConstant(left.asNumber() >= right.asNumber(), left, right); } }