public class SqlCastFunction extends SqlFunction
kind, MDX_PRECEDENCE, NL| Constructor and Description |
|---|
SqlCastFunction() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkOperandTypes(SqlCallBinding callBinding,
boolean throwOnFailure)
Makes sure that the number and types of arguments are allowable.
|
SqlMonotonicity |
getMonotonicity(SqlCall call,
SqlValidatorScope scope)
Returns whether this operator is monotonic.
|
SqlOperandCountRange |
getOperandCountRange()
Returns a constraint on the number of operands expected by this operator.
|
String |
getSignatureTemplate(int operandsCount)
Returns a template describing how the operator signature is to be built.
|
SqlSyntax |
getSyntax()
Returns the syntactic type of this operator, never null.
|
RelDataType |
inferReturnType(SqlOperatorBinding opBinding)
Infers the return type of an invocation of this operator; only called
after the number and types of operands have already been validated.
|
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.
|
deriveType, getFunctionType, getNameAsId, getParamTypes, getSqlIdentifier, isQuantifierAllowed, validateCall, validateQuantifieracceptCall, acceptCall, adjustType, allowsFraming, argumentMustBeScalar, checkOperandCount, createCall, createCall, createCall, createCall, equals, getAllowedSignatures, getAllowedSignatures, getKind, getLeftPrec, getName, getOperandTypeChecker, getOperandTypeInference, getReturnTypeInference, getRightPrec, hashCode, inferReturnType, isAggregator, isDeterministic, isDynamicFunction, isName, leftPrec, preValidateCall, requiresDecimalExpansion, requiresOrder, rewriteCall, rightPrec, toString, unparseListClause, unparseListClause, validateOperands, validRexOperandspublic RelDataType inferReturnType(SqlOperatorBinding opBinding)
SqlOperatorSqlReturnTypeInference to the constructor.inferReturnType in class SqlOperatoropBinding - description of invocation (not necessarily a
SqlCall)public String getSignatureTemplate(int operandsCount)
SqlOperatorgetSignatureTemplate in class SqlOperatoroperandsCount - is used with functions that can take a variable
number of operandspublic SqlOperandCountRange getOperandCountRange()
SqlOperatorSqlOperandTypeChecker associated with this
operator.getOperandCountRange in class SqlOperatorpublic boolean checkOperandTypes(SqlCallBinding callBinding, boolean throwOnFailure)
checkOperandTypes in class SqlOperatorcallBinding - description of callthrowOnFailure - whether to throw an exception if check fails
(otherwise returns false in that case)public SqlSyntax getSyntax()
SqlOperatorgetSyntax in class SqlFunctionpublic 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 SqlMonotonicity getMonotonicity(SqlCall call, SqlValidatorScope scope)
SqlOperatorDefault implementation returns SqlMonotonicity.NOT_MONOTONIC.
getMonotonicity in class SqlOperatorcall - Call to this operatorscope - Scope in which the call occursCopyright © 2012–2015 The Apache Software Foundation. All rights reserved.