Package org.apache.calcite.sql.type
Class OperandHandlers
java.lang.Object
org.apache.calcite.sql.type.OperandHandlers
Strategies for handling operands.
This class defines singleton instances of strategy objects for operand
expansion. OperandTypes, ReturnTypes and InferTypes
provide similar strategies for operand type checking and inference,
and operator return type inference.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final SqlOperandHandlerThe default operand handler visits all operands.static final SqlOperandHandlerAn operand handler that tries to convert operand #1 (0-based) into a time frame. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic SqlOperandHandlerCreates an operand handler that applies a function to a call.
-
Field Details
-
DEFAULT
The default operand handler visits all operands. -
OPERAND_1_MIGHT_BE_TIME_FRAME
An operand handler that tries to convert operand #1 (0-based) into a time frame.For example, the
DATE_TRUNCfunction uses this; the callsDATE_TRUNC('month', orders.order_date),DATE_TRUNC(orders.order_date, MONTH),DATE_TRUNC(orders.order_date, MINUTE15)are all valid. The last uses a user-defined time frame, which appears to the validator as aSqlIdentifierand is then converted to aSqlIntervalQualifierwhen it matches a defined time frame.
-
-
Constructor Details
-
OperandHandlers
public OperandHandlers()
-
-
Method Details
-
of
Creates an operand handler that applies a function to a call.
-