public class SqlFloorFunction extends SqlMonotonicUnaryFunction
kind, MDX_PRECEDENCE, NL| Constructor and Description |
|---|
SqlFloorFunction(SqlKind kind) |
| Modifier and Type | Method and Description |
|---|---|
SqlMonotonicity |
getMonotonicity(SqlOperatorBinding call)
Returns whether a call to this operator is monotonic.
|
static SqlCall |
replaceTimeUnitOperand(SqlCall call,
String literal,
SqlParserPos pos)
Copies a
SqlCall, replacing the time unit operand with the given
literal. |
void |
unparse(SqlWriter writer,
SqlCall call,
int leftPrec,
int rightPrec)
Writes a SQL representation of a call to this operator to a writer,
including parentheses if the operators on either side are of greater
precedence.
|
static void |
unparseDatetimeFunction(SqlWriter writer,
SqlCall call,
String funName,
Boolean datetimeFirst)
Most dialects that natively support datetime floor will use this.
|
deriveType, getFunctionType, getNameAsId, getParamNames, getParamTypes, getSqlIdentifier, getSyntax, isQuantifierAllowed, validateCall, validateQuantifieracceptCall, acceptCall, adjustType, allowsFraming, argumentMustBeScalar, checkOperandCount, checkOperandTypes, constructArgNameList, constructArgTypeList, constructOperandList, createCall, createCall, createCall, createCall, equals, getAllowedSignatures, getAllowedSignatures, getKind, getLeftPrec, getMonotonicity, getName, getOperandCountRange, getOperandTypeChecker, getOperandTypeInference, getReturnTypeInference, getRightPrec, getSignatureTemplate, hashCode, inferReturnType, inferReturnType, isAggregator, isDeterministic, isDynamicFunction, isGroup, isGroupAuxiliary, isName, leftPrec, preValidateCall, requiresDecimalExpansion, requiresOrder, requiresOver, rewriteCall, rightPrec, toString, unparseListClause, unparseListClause, validateOperands, validRexOperandspublic SqlFloorFunction(SqlKind kind)
public SqlMonotonicity getMonotonicity(SqlOperatorBinding call)
SqlOperatorDefault implementation returns SqlMonotonicity.NOT_MONOTONIC.
getMonotonicity in class SqlMonotonicUnaryFunctioncall - Call to this operator with particular arguments and information
about the monotonicity of the argumentspublic void unparse(SqlWriter writer, SqlCall call, int leftPrec, int rightPrec)
SqlOperatorThe default implementation of this method delegates to
SqlSyntax.unparse(org.apache.calcite.sql.SqlWriter, org.apache.calcite.sql.SqlOperator, org.apache.calcite.sql.SqlCall, int, int).
unparse in class SqlFunctionpublic static SqlCall replaceTimeUnitOperand(SqlCall call, String literal, SqlParserPos pos)
SqlCall, replacing the time unit operand with the given
literal.call - Callliteral - Literal to replace time unit withpos - Parser positionpublic static void unparseDatetimeFunction(SqlWriter writer, SqlCall call, String funName, Boolean datetimeFirst)
writer - SqlWritercall - SqlCallfunName - Name of the sql function to calldatetimeFirst - Specify the order of the datetime & timeUnit
argumentsCopyright © 2012–2018 The Apache Software Foundation. All rights reserved.