Package org.apache.calcite.test
Class MockSqlOperatorTable.TopNTableFunction
java.lang.Object
org.apache.calcite.sql.SqlOperator
org.apache.calcite.sql.SqlFunction
org.apache.calcite.test.MockSqlOperatorTable.TopNTableFunction
- All Implemented Interfaces:
- SqlTableFunction
- Enclosing class:
- MockSqlOperatorTable
public static class MockSqlOperatorTable.TopNTableFunction
extends SqlFunction
implements SqlTableFunction
"TopN" user-defined table function. First parameter is input table
 with set semantics.
- 
Field SummaryFields inherited from class org.apache.calcite.sql.SqlOperatorkind, MDX_PRECEDENCE, NL
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionbooleanargumentMustBeScalar(int ordinal) Returns whether theordinalth argument to this operator must be scalar (as opposed to a query).Returns the record type of the table yielded by this function when applied to given arguments.tableCharacteristic(int ordinal) Returns the table parameter characteristics forordinalth parameter to this table function.Methods inherited from class org.apache.calcite.sql.SqlFunctionderiveType, getFunctionType, getNameAsId, getParamNames, getParamTypes, getSqlIdentifier, getSyntax, isQuantifierAllowed, unparse, validateCall, validateQuantifierMethods inherited from class org.apache.calcite.sql.SqlOperatoracceptCall, acceptCall, adjustType, allowsFraming, checkOperandCount, checkOperandTypes, constructArgNameList, constructArgTypeList, constructOperandList, createCall, createCall, createCall, createCall, createCall, createCall, createCall, deriveOperandType, equals, getAllowedSignatures, getAllowedSignatures, getKind, getLeftPrec, getMonotonicity, getMonotonicity, getName, getOperandCountRange, getOperandTypeChecker, getOperandTypeInference, getReturnTypeInference, getRightPrec, getSignatureTemplate, getSqlCallFactory, getStrongPolicyInference, hashCode, inferReturnType, inferReturnType, isAggregator, isDeterministic, isDynamicFunction, isGroup, isGroupAuxiliary, isName, isSymmetrical, leftPrec, not, preValidateCall, requiresDecimalExpansion, requiresOrder, requiresOver, reverse, rewriteCall, rightPrec, toString, unparseListClause, unparseListClause, validateOperands, validRexOperands
- 
Constructor Details- 
TopNTableFunctionpublic TopNTableFunction()
 
- 
- 
Method Details- 
getRowTypeInferenceDescription copied from interface:SqlTableFunctionReturns the record type of the table yielded by this function when applied to given arguments. Only literal arguments are passed, non-literal are replaced with default values (null, 0, false, etc).- Specified by:
- getRowTypeInferencein interface- SqlTableFunction
- Returns:
- strategy to infer the row type of a call to this function
 
- 
tableCharacteristicDescription copied from interface:SqlTableFunctionReturns the table parameter characteristics forordinalth parameter to this table function.Returns nullif theordinalth argument is not table parameter or theordinalis smaller than 0 or theordinalis greater than or equals to the number of parameters.- Specified by:
- tableCharacteristicin interface- SqlTableFunction
 
- 
argumentMustBeScalarpublic boolean argumentMustBeScalar(int ordinal) Description copied from class:SqlOperatorReturns whether theordinalth argument to this operator must be scalar (as opposed to a query).If true (the default), the validator will attempt to convert the argument into a scalar sub-query, which must have one column and return at most one row. Operators such as SELECTandEXISTSoverride this method.- Overrides:
- argumentMustBeScalarin class- SqlOperator
 
 
-