Class ColumnReader<V extends ValueVector>
java.lang.Object
org.apache.drill.exec.store.parquet.columnreaders.ColumnReader<V>
- Direct Known Subclasses:
NullableFixedByteAlignedReaders.CorruptionDetectingNullableDateReader,NullableFixedByteAlignedReaders.NullableCorruptDateReader,NullableFixedByteAlignedReaders.NullableDateReader,NullableFixedByteAlignedReaders.NullableIntervalReader,VarLengthColumn
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedColumnReader(ParquetRecordReader parentReader, org.apache.parquet.column.ColumnDescriptor descriptor, org.apache.parquet.hadoop.metadata.ColumnChunkMetaData columnChunkMetaData, boolean fixedLength, V v, org.apache.parquet.format.SchemaElement schemaElement) -
Method Summary
Modifier and TypeMethodDescriptionintcapacity()protected booleanvoidclear()booleandetermineSize(long recordsReadInCurrentPass) Determines the size of a single value in a variable column.intprotected voidprotected voidprotected booleanprocessPageData(int recordsToReadInThisPass) voidprocessPages(long recordsToReadInThisPass) processPagesAsync(long recordsToReadInThisPass) protected abstract voidreadField(long recordsToRead) static intreadIntLittleEndian(DrillBuf in, int offset) This is copied out of Parquet library, didn't want to deal with the unnecessary throws statement they had declaredbooleanreadPage()Read a page.protected voidreadRecords(int recordsToRead) readRecordsAsync(int recordsToRead) protected intreadRecordsInBulk(int recordsToReadInThisPass) voidreadValues(long recordsToRead) protected booleanvoidreset()protected intvoidvoid
-
Field Details
-
DICTIONARY_ENCODINGS
-
VALUE_ENCODINGS
-
vectorData
-
-
Constructor Details
-
ColumnReader
protected ColumnReader(ParquetRecordReader parentReader, org.apache.parquet.column.ColumnDescriptor descriptor, org.apache.parquet.hadoop.metadata.ColumnChunkMetaData columnChunkMetaData, boolean fixedLength, V v, org.apache.parquet.format.SchemaElement schemaElement) throws ExecutionSetupException - Throws:
ExecutionSetupException
-
-
Method Details
-
getRecordsReadInCurrentPass
public int getRecordsReadInCurrentPass() -
processPagesAsync
-
processPages
- Throws:
IOException
-
clear
public void clear() -
readValues
public void readValues(long recordsToRead) -
readField
protected abstract void readField(long recordsToRead) -
determineSize
Determines the size of a single value in a variable column. Return value indicates if we have finished a row group and should stop reading- Parameters:
recordsReadInCurrentPass- records read in current pass- Returns:
- true if we should stop reading
- Throws:
IOException
-
readRecordsAsync
-
readRecords
protected void readRecords(int recordsToRead) -
readRecordsInBulk
- Throws:
IOException
-
recordsRequireDecoding
protected boolean recordsRequireDecoding() -
processPageData
- Throws:
IOException
-
updatePosition
public void updatePosition() -
updateReadyToReadPosition
public void updateReadyToReadPosition() -
reset
public void reset() -
capacity
public int capacity() -
readPageAsync
-
readPage
Read a page. If we need more data, exit the read loop and return true.- Returns:
- true if we need more data and page is not read successfully
- Throws:
IOException
-
totalValuesReadAndReadyToReadInPage
protected int totalValuesReadAndReadyToReadInPage() -
postPageRead
protected void postPageRead() -
hitRowGroupEnd
protected void hitRowGroupEnd() -
checkVectorCapacityReached
protected boolean checkVectorCapacityReached() -
readIntLittleEndian
This is copied out of Parquet library, didn't want to deal with the unnecessary throws statement they had declared- Parameters:
in- incoming dataoffset- offset- Returns:
- little endian integer
-