OmniSciDB  6686921089
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType > Class Template Reference

#include <ParquetFixedLengthEncoder.h>

+ Inheritance diagram for foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >:
+ Collaboration diagram for foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >:

Public Member Functions

 ParquetUnsignedFixedLengthEncoder (Data_Namespace::AbstractBuffer *buffer, const ColumnDescriptor *column_desciptor, const parquet::ColumnDescriptor *parquet_column_descriptor)
 
 ParquetUnsignedFixedLengthEncoder (Data_Namespace::AbstractBuffer *buffer, const size_t omnisci_data_type_byte_size, const size_t parquet_data_type_byte_size)
 
void encodeAndCopy (const int8_t *parquet_data_bytes, int8_t *omnisci_data_bytes) override
 
void validate (std::shared_ptr< parquet::Statistics > stats, const SQLTypeInfo &column_type) const override
 
void validate (const int8_t *parquet_data, const int64_t j, const SQLTypeInfo &column_type) const override
 
- Public Member Functions inherited from foreign_storage::TypedParquetInPlaceEncoder< V, T, NullType >
 TypedParquetInPlaceEncoder (Data_Namespace::AbstractBuffer *buffer, const ColumnDescriptor *column_desciptor, const parquet::ColumnDescriptor *parquet_column_descriptor)
 
 TypedParquetInPlaceEncoder (Data_Namespace::AbstractBuffer *buffer, const size_t omnisci_data_type_byte_size, const size_t parquet_data_type_byte_size)
 
void validate (const int8_t *parquet_data, const int64_t j, const SQLTypeInfo &column_type) const override
 
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
 
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
 
void encodeAndCopyContiguous (const int8_t *parquet_data_bytes, int8_t *omnisci_data_bytes, const size_t num_elements) override
 
void setNull (int8_t *omnisci_data_bytes) override
 
void copy (const int8_t *omnisci_data_bytes_source, int8_t *omnisci_data_bytes_destination) override
 
std::shared_ptr< ChunkMetadatagetRowGroupMetadata (const parquet::RowGroupMetaData *group_metadata, const int parquet_column_index, const SQLTypeInfo &column_type) override
 
- Public Member Functions inherited from foreign_storage::ParquetInPlaceEncoder
 ParquetInPlaceEncoder (Data_Namespace::AbstractBuffer *buffer, const size_t omnisci_data_type_byte_size, const size_t parquet_data_type_byte_size)
 
- Public Member Functions inherited from foreign_storage::ParquetScalarEncoder
 ParquetScalarEncoder (Data_Namespace::AbstractBuffer *buffer)
 
- Public Member Functions inherited from foreign_storage::ParquetEncoder
 ParquetEncoder (Data_Namespace::AbstractBuffer *buffer)
 
virtual ~ParquetEncoder ()=default
 

Additional Inherited Members

- Protected Member Functions inherited from foreign_storage::TypedParquetInPlaceEncoder< V, T, NullType >
virtual bool encodingIsIdentityForSameTypes () const
 
std::pair< T, T > getUnencodedStats (std::shared_ptr< parquet::Statistics > stats) const
 
- Static Protected Member Functions inherited from foreign_storage::ParquetEncoder
static std::shared_ptr
< ChunkMetadata
createMetadata (const SQLTypeInfo &column_type)
 
static void throwNotNullViolation (const std::string &parquet_column_name)
 
static void validateNullCount (const std::string &parquet_column_name, int64_t null_count, const SQLTypeInfo &column_type)
 
- Protected Attributes inherited from foreign_storage::ParquetInPlaceEncoder
const size_t omnisci_data_type_byte_size_
 
const size_t parquet_data_type_byte_size_
 
- Protected Attributes inherited from foreign_storage::ParquetEncoder
Data_Namespace::AbstractBufferbuffer_
 

Detailed Description

template<typename V, typename T, typename U, typename NullType = V>
class foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >

Definition at line 143 of file ParquetFixedLengthEncoder.h.

Constructor & Destructor Documentation

template<typename V , typename T , typename U , typename NullType = V>
foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >::ParquetUnsignedFixedLengthEncoder ( Data_Namespace::AbstractBuffer buffer,
const ColumnDescriptor column_desciptor,
const parquet::ColumnDescriptor *  parquet_column_descriptor 
)
inline

Definition at line 147 of file ParquetFixedLengthEncoder.h.

151  : TypedParquetInPlaceEncoder<V, T, NullType>(buffer,
152  column_desciptor,
153  parquet_column_descriptor) {}
template<typename V , typename T , typename U , typename NullType = V>
foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >::ParquetUnsignedFixedLengthEncoder ( Data_Namespace::AbstractBuffer buffer,
const size_t  omnisci_data_type_byte_size,
const size_t  parquet_data_type_byte_size 
)
inline

Definition at line 155 of file ParquetFixedLengthEncoder.h.

158  : TypedParquetInPlaceEncoder<V, T, NullType>(buffer,
159  omnisci_data_type_byte_size,
160  parquet_data_type_byte_size) {}

Member Function Documentation

template<typename V , typename T , typename U , typename NullType = V>
void foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >::encodeAndCopy ( const int8_t *  parquet_data_bytes,
int8_t *  omnisci_data_bytes 
)
inlineoverridevirtual

Implements foreign_storage::ParquetScalarEncoder.

Definition at line 162 of file ParquetFixedLengthEncoder.h.

References omnisci.dtypes::T.

163  {
164  const auto& parquet_data_value = reinterpret_cast<const T*>(parquet_data_bytes)[0];
165  auto& omnisci_data_value = reinterpret_cast<V*>(omnisci_data_bytes)[0];
166  omnisci_data_value = static_cast<U>(parquet_data_value);
167  }
template<typename V , typename T , typename U , typename NullType = V>
void foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >::validate ( std::shared_ptr< parquet::Statistics >  stats,
const SQLTypeInfo column_type 
) const
inlineoverridevirtual

Implements foreign_storage::ParquetMetadataValidator.

Definition at line 169 of file ParquetFixedLengthEncoder.h.

References foreign_storage::TypedParquetInPlaceEncoder< V, T, NullType >::getUnencodedStats(), SQLTypeInfo::is_integer(), and foreign_storage::IntegralFixedLengthBoundsValidator< T >::validateValue().

170  {
171  if (!column_type.is_integer()) { // do not validate non-integral types
172  return;
173  }
174  auto [unencoded_stats_min, unencoded_stats_max] =
177  column_type);
179  column_type);
180  }
static void validateValue(const D &data_value, const SQLTypeInfo &column_type)
bool is_integer() const
Definition: sqltypes.h:511
std::pair< T, T > getUnencodedStats(std::shared_ptr< parquet::Statistics > stats) const

+ Here is the call graph for this function:

template<typename V , typename T , typename U , typename NullType = V>
void foreign_storage::ParquetUnsignedFixedLengthEncoder< V, T, U, NullType >::validate ( const int8_t *  parquet_data,
const int64_t  j,
const SQLTypeInfo column_type 
) const
inlineoverridevirtual

Implements foreign_storage::ParquetScalarEncoder.

Definition at line 182 of file ParquetFixedLengthEncoder.h.

References omnisci.dtypes::T, and foreign_storage::IntegralFixedLengthBoundsValidator< T >::validateValue().

184  {
185  const auto& parquet_data_value = reinterpret_cast<const T*>(parquet_data)[j];
186  IntegralFixedLengthBoundsValidator<U>::validateValue(parquet_data_value, column_type);
187  }
static void validateValue(const D &data_value, const SQLTypeInfo &column_type)

+ Here is the call graph for this function:


The documentation for this class was generated from the following file: