Package org.apache.orc.impl
Class OrcFilterContextImpl
java.lang.Object
org.apache.orc.impl.OrcFilterContextImpl
- All Implemented Interfaces:
org.apache.hadoop.hive.ql.io.filter.FilterContext,org.apache.hadoop.hive.ql.io.filter.MutableFilterContext,OrcFilterContext
This defines the input for any filter operation. This is an extension of
[[
VectorizedRowBatch]] with schema.
This offers a convenience method of finding the column vector from a given column name that the filters can invoke to get access to the column vector.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.hadoop.hive.ql.exec.vector.ColumnVector[]findColumnVector(String name) Retrieves the column vector that matches the specified name.org.apache.hadoop.hive.ql.exec.vector.ColumnVector[]getCols()int[]intbooleanvoidreset()setBatch(@NotNull org.apache.hadoop.hive.ql.exec.vector.VectorizedRowBatch batch) voidsetFilterContext(boolean selectedInUse, int[] selected, int selectedSize) voidsetSelected(int[] ints) voidsetSelectedInUse(boolean b) voidsetSelectedSize(int i) int[]updateSelected(int i) booleanMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.hive.ql.io.filter.MutableFilterContext
immutable
-
Constructor Details
-
OrcFilterContextImpl
-
-
Method Details
-
setBatch
public OrcFilterContext setBatch(@NotNull @NotNull org.apache.hadoop.hive.ql.exec.vector.VectorizedRowBatch batch) -
setFilterContext
public void setFilterContext(boolean selectedInUse, int[] selected, int selectedSize) - Specified by:
setFilterContextin interfaceorg.apache.hadoop.hive.ql.io.filter.MutableFilterContext
-
validateSelected
public boolean validateSelected()- Specified by:
validateSelectedin interfaceorg.apache.hadoop.hive.ql.io.filter.MutableFilterContext
-
updateSelected
public int[] updateSelected(int i) - Specified by:
updateSelectedin interfaceorg.apache.hadoop.hive.ql.io.filter.MutableFilterContext
-
setSelectedInUse
public void setSelectedInUse(boolean b) - Specified by:
setSelectedInUsein interfaceorg.apache.hadoop.hive.ql.io.filter.MutableFilterContext
-
setSelected
public void setSelected(int[] ints) - Specified by:
setSelectedin interfaceorg.apache.hadoop.hive.ql.io.filter.MutableFilterContext
-
setSelectedSize
public void setSelectedSize(int i) - Specified by:
setSelectedSizein interfaceorg.apache.hadoop.hive.ql.io.filter.MutableFilterContext
-
reset
public void reset()- Specified by:
resetin interfaceorg.apache.hadoop.hive.ql.io.filter.FilterContext
-
isSelectedInUse
public boolean isSelectedInUse()- Specified by:
isSelectedInUsein interfaceorg.apache.hadoop.hive.ql.io.filter.FilterContext
-
getSelected
public int[] getSelected()- Specified by:
getSelectedin interfaceorg.apache.hadoop.hive.ql.io.filter.FilterContext
-
getSelectedSize
public int getSelectedSize()- Specified by:
getSelectedSizein interfaceorg.apache.hadoop.hive.ql.io.filter.FilterContext
-
getCols
public org.apache.hadoop.hive.ql.exec.vector.ColumnVector[] getCols() -
findColumnVector
Description copied from interface:OrcFilterContextRetrieves the column vector that matches the specified name. Allows support for nested struct references e.g. order.date where date is a field in a struct called order.- Specified by:
findColumnVectorin interfaceOrcFilterContext- Parameters:
name- The column name whose vector should be retrieved- Returns:
- The column vectors from the root to the column name. The array levels match the name levels with Array[0] referring to the top level, followed by the subsequent levels. For example of order.date Array[0] refers to order and Array[1] refers to date
-