Class AbstractRangePartitionFunction
java.lang.Object
org.apache.drill.exec.planner.physical.AbstractRangePartitionFunction
- All Implemented Interfaces:
PartitionFunction
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract inteval(int index, int numPartitions) Evaluate a partitioning function for a particular row index and return the partition idReturns a FieldReference (LogicalExpression) for the partition functionabstract List<FieldReference> Return the list of FieldReferences that participate in the partitioning functionabstract voidsetup(List<VectorWrapper<?>> partitionKeys) Setup method for the partitioning function
-
Field Details
-
RANGE_PARTITION_EXPR_NAME
- See Also:
-
-
Constructor Details
-
AbstractRangePartitionFunction
public AbstractRangePartitionFunction()
-
-
Method Details
-
getPartitionRefList
Description copied from interface:PartitionFunctionReturn the list of FieldReferences that participate in the partitioning function- Specified by:
getPartitionRefListin interfacePartitionFunction- Returns:
- list of FieldReferences
-
setup
Description copied from interface:PartitionFunctionSetup method for the partitioning function- Specified by:
setupin interfacePartitionFunction- Parameters:
partitionKeys- a list of partition columns on which range partitioning is needed
-
eval
public abstract int eval(int index, int numPartitions) Description copied from interface:PartitionFunctionEvaluate a partitioning function for a particular row index and return the partition id- Specified by:
evalin interfacePartitionFunction- Parameters:
index- the integer index into the partition keys vector for a specific 'row' of valuesnumPartitions- the max number of partitions that are allowed- Returns:
- partition id, an integer value
-
getPartitionFieldRef
Description copied from interface:PartitionFunctionReturns a FieldReference (LogicalExpression) for the partition function- Specified by:
getPartitionFieldRefin interfacePartitionFunction- Returns:
- FieldReference for the partition function
-