Package org.h2.expression.function
Class MathFunction1
java.lang.Object
org.h2.expression.Expression
org.h2.expression.Operation1
org.h2.expression.function.Function1
org.h2.expression.function.MathFunction1
- All Implemented Interfaces:
NamedExpression,HasSQL,Typed
A math function with one argument and DOUBLE PRECISION result.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intACOS().static final intASIN().static final intATAN().static final intCOS().static final intCOSH().static final intCOT() (non-standard).static final intDEGREES() (non-standard).static final intEXP().static final intLN().static final intLOG10().static final intRADIANS() (non-standard).static final intSIN().static final intSINH().static final intSQRT().static final intTAN().static final intTANH().Fields inherited from class org.h2.expression.Operation1
arg, typeFields inherited from class org.h2.expression.Expression
AUTO_PARENTHESES, MAP_IN_AGGREGATE, MAP_IN_WINDOW, MAP_INITIAL, WITH_PARENTHESES, WITHOUT_PARENTHESESFields inherited from interface org.h2.util.HasSQL
ADD_PLAN_INFORMATION, DEFAULT_SQL_FLAGS, NO_CASTS, QUOTE_ONLY_WHEN_REQUIRED, REPLACE_LOBS_FOR_TRACE, TRACE_SQL_FLAGS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()Get the name.getValue(SessionLocal session) Return the resulting value for the current row.optimize(SessionLocal session) Try to optimize the expression.Methods inherited from class org.h2.expression.function.Function1
getUnenclosedSQLMethods inherited from class org.h2.expression.Operation1
getCost, getSubexpression, getSubexpressionCount, getType, isEverything, mapColumns, setEvaluatable, updateAggregateMethods inherited from class org.h2.expression.Expression
addFilterConditions, createIndexConditions, getAlias, getBooleanValue, getColumnName, getColumnNameForView, getEnclosedSQL, getNonAliasExpression, getNotIfPossible, getNullable, getSchemaName, getSQL, getSQL, getSQL, getSQL, getTableAlias, getTableName, getTypeIfStaticallyKnown, getWhenSQL, getWhenValue, isConstant, isIdentity, isNullConstant, isValueSet, isWhenConditionOperand, needParentheses, optimizeCondition, toString, writeExpressions, writeExpressionsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.h2.util.HasSQL
getTraceSQL
-
Field Details
-
SIN
public static final int SINSIN().- See Also:
-
COS
public static final int COSCOS().- See Also:
-
TAN
public static final int TANTAN().- See Also:
-
COT
public static final int COTCOT() (non-standard).- See Also:
-
SINH
public static final int SINHSINH().- See Also:
-
COSH
public static final int COSHCOSH().- See Also:
-
TANH
public static final int TANHTANH().- See Also:
-
ASIN
public static final int ASINASIN().- See Also:
-
ACOS
public static final int ACOSACOS().- See Also:
-
ATAN
public static final int ATANATAN().- See Also:
-
LOG10
public static final int LOG10LOG10().- See Also:
-
LN
public static final int LNLN().- See Also:
-
EXP
public static final int EXPEXP().- See Also:
-
SQRT
public static final int SQRTSQRT().- See Also:
-
DEGREES
public static final int DEGREESDEGREES() (non-standard).- See Also:
-
RADIANS
public static final int RADIANSRADIANS() (non-standard).- See Also:
-
-
Constructor Details
-
MathFunction1
-
-
Method Details
-
getValue
Description copied from class:ExpressionReturn the resulting value for the current row.- Specified by:
getValuein classExpression- Parameters:
session- the session- Returns:
- the result
-
optimize
Description copied from class:ExpressionTry to optimize the expression.- Specified by:
optimizein classExpression- Parameters:
session- the session- Returns:
- the optimized expression
-
getName
Description copied from interface:NamedExpressionGet the name.- Returns:
- the name in uppercase
-