Class ShortTransfer
java.lang.Object
com.illumon.iris.db.v2.parquet.transfer.ShortTransfer
- All Implemented Interfaces:
TransferObject<IntBuffer>
,SafeCloseable
,AutoCloseable
public class ShortTransfer extends Object implements TransferObject<IntBuffer>
-
Constructor Summary
Constructors Constructor Description ShortTransfer(ColumnSource<?> columnSource, int targetSize)
-
Method Summary
Modifier and Type Method Description void
close()
void
fetchData(OrderedKeys rs)
Copy the data from the upstreamColumnSource
into this object in preparation for writingIntBuffer
getBuffer()
Get the buffer suitable for writing to a Parquet fileint
rowCount()
Get the number of rows contained within the current transfer set to be written<T extends Comparable<T>>
voidupdateStatistics(org.apache.parquet.column.statistics.Statistics<T> stats)
After a sequence of calls toTransferObject.fetchData(OrderedKeys)
this may be called to append statistic information into the Parquet footer for readers.
-
Constructor Details
-
Method Details
-
getBuffer
Description copied from interface:TransferObject
Get the buffer suitable for writing to a Parquet file- Specified by:
getBuffer
in interfaceTransferObject<IntBuffer>
- Returns:
- the buffer
-
rowCount
public int rowCount()Description copied from interface:TransferObject
Get the number of rows contained within the current transfer set to be written- Specified by:
rowCount
in interfaceTransferObject<IntBuffer>
- Returns:
- the number of rows that are ready to write to the Parquet file
-
fetchData
Description copied from interface:TransferObject
Copy the data from the upstreamColumnSource
into this object in preparation for writing- Specified by:
fetchData
in interfaceTransferObject<IntBuffer>
- Parameters:
rs
- theOrderedKeys
to copy
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceSafeCloseable
-
updateStatistics
public <T extends Comparable<T>> void updateStatistics(@NotNull org.apache.parquet.column.statistics.Statistics<T> stats)Description copied from interface:TransferObject
After a sequence of calls toTransferObject.fetchData(OrderedKeys)
this may be called to append statistic information into the Parquet footer for readers.- Specified by:
updateStatistics
in interfaceTransferObject<IntBuffer>
-