19 #include <parquet/types.h>
26 namespace foreign_storage {
31 std::shared_ptr<ParquetScalarEncoder> scalar_encoder,
51 const int16_t* rep_levels,
52 const int64_t values_read,
53 const int64_t levels_read,
59 for (int64_t j = 0; j < values_read; ++j) {
62 }
catch (
const std::runtime_error& error) {
67 appendData(def_levels, rep_levels, values_read, levels_read, values);
92 std::shared_ptr<int8_t> buffer(
new int8_t[num_bytes],
93 std::default_delete<int8_t[]>());
94 memcpy(buffer.get(), data, num_bytes);
120 if (invalid_indices.empty()) {
void eraseInvalidData(const FindContainer &invalid_indices)
virtual void appendArrayItem(const int64_t encoded_index)
std::vector< int8_t > data_buffer_bytes_
bool isLastArrayEmpty() const
size_t omnisci_data_type_byte_size_
size_t sizeOfLastArray() const
void appendToArrayDatumBuffer()
static ArrayDatum composeNullArray(const SQLTypeInfo &ti)
void resetLastArrayMetadata() override
bool isLastArrayNull() const
void eraseInvalidIndicesInBuffer(const InvalidRowGroupIndices &invalid_indices) override
void appendData(const int16_t *def_levels, const int16_t *rep_levels, const int64_t values_read, const int64_t levels_read, int8_t *values) override
std::conditional_t< is_cuda_compiler(), DeviceArrayDatum, HostArrayDatum > ArrayDatum
std::set< int64_t > InvalidRowGroupIndices
void appendArrayItem(const int64_t encoded_index) override
ParquetArrayImportEncoder(Data_Namespace::AbstractBuffer *data_buffer, std::shared_ptr< ParquetScalarEncoder > scalar_encoder, const ColumnDescriptor *column_desciptor)
An AbstractBuffer is a unit of data management for a data manager.
specifies the content in-memory of a row in the column metadata table
ArrayDatum convertToArrayDatum(const int8_t *data, const size_t num_elements)
const ColumnDescriptor * column_descriptor_
TypedParquetStorageBuffer< ArrayDatum > * array_datum_buffer_
void processLastArray() override
bool g_enable_watchdog false
ArrayDatum getNullArrayDatum()
virtual void resetLastArrayMetadata()
void validateAndAppendData(const int16_t *def_levels, const int16_t *rep_levels, const int64_t values_read, const int64_t levels_read, int8_t *values, const SQLTypeInfo &column_type, InvalidRowGroupIndices &invalid_indices) override
std::vector< bool > is_valid_item_
InvalidRowGroupIndices * invalid_indices_
size_t num_array_assembled_
void appendElement(const Type &element)
std::shared_ptr< ParquetScalarEncoder > scalar_encoder_
void appendArraysToBuffer() override