Package org.apache.calcite.test
Class SqlOperatorTest.CustomTimeFrameTypeSystem
java.lang.Object
org.apache.calcite.rel.type.DelegatingTypeSystem
org.apache.calcite.test.SqlOperatorTest.CustomTimeFrameTypeSystem
- All Implemented Interfaces:
RelDataTypeSystem
- Enclosing class:
- SqlOperatorTest
Type system whose constructor reads from a thread-local. You must invoke
the constructor in the same thread, but once constructed you can use from
other threads.
It's a bit strange, but the best we can do to pass objects via Avatica's plugin system until [CALCITE-5295] Read the values of plugins (such as connect string properties) from ThreadLocal fields is fixed.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final TryThreadLocal<RelDataTypeSystem>
Assign to this thread-local before you instantiate a FooTypeSystem (in the same thread) and your FooTypeSystem will behave in the same way.Fields inherited from interface org.apache.calcite.rel.type.RelDataTypeSystem
DEFAULT
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.calcite.rel.type.DelegatingTypeSystem
deriveAvgAggType, deriveCovarType, deriveFractionalRankType, deriveRankType, deriveSumType, deriveTimeFrameSet, getDefaultPrecision, getLiteral, getMaxNumericPrecision, getMaxNumericScale, getMaxPrecision, getMaxScale, getNumTypeRadix, isAutoincrement, isCaseSensitive, isSchemaCaseSensitive, shouldConvertRaggedUnionTypesToVarying
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.calcite.rel.type.RelDataTypeSystem
deriveDecimalDivideType, deriveDecimalModType, deriveDecimalMultiplyType, deriveDecimalPlusType, shouldUseDoubleMultiplication
-
Field Details
-
DELEGATE
Assign to this thread-local before you instantiate a FooTypeSystem (in the same thread) and your FooTypeSystem will behave in the same way.
-
-
Constructor Details
-
CustomTimeFrameTypeSystem
public CustomTimeFrameTypeSystem()Creates a CustomTimeFrameTypeSystem, taking a snapshot ofDELEGATE
.
-