pub enum ParquetStatisticsPolicy {
KeepAll,
SkipAll,
SkipExcept(Arc<HashSet<usize>>),
}Expand description
Enum to control decoding of some Parquet statistics fields.
§Example
use parquet::file::metadata::ParquetStatisticsPolicy;
use parquet::file::serialized_reader::ReadOptionsBuilder;
use parquet::arrow::arrow_reader::ArrowReaderOptions;
// Set arrow options to skip encoding statistics for all columns.
let options =
ArrowReaderOptions::new().with_encoding_stats_policy(ParquetStatisticsPolicy::SkipAll);
// Set serialized reader options to decode encoding statistics for all columns.
let options =
ReadOptionsBuilder::new().with_encoding_stats_policy(ParquetStatisticsPolicy::KeepAll)
.build();
// Set arrow options to skip encoding statistics for all columns, but to decode statistics
// for columns 0 and 1.
let options = ArrowReaderOptions::new()
.with_encoding_stats_policy(ParquetStatisticsPolicy::skip_except(&[0, 1]));Variants§
KeepAll
Decode the relevant statistics for all columns.
SkipAll
Skip decoding the relevant statistics for all columns.
SkipExcept(Arc<HashSet<usize>>)
Skip decoding the relevant statistics for all columns not in the provided set of column indices.
Implementations§
Source§impl ParquetStatisticsPolicy
impl ParquetStatisticsPolicy
Sourcepub fn skip_except(keep: &[usize]) -> Self
pub fn skip_except(keep: &[usize]) -> Self
Create a ParquetStatisticsPolicy to skip all columns except those in keep.
If keep is empty, then this returns Self::SkipAll
Trait Implementations§
Source§impl Clone for ParquetStatisticsPolicy
impl Clone for ParquetStatisticsPolicy
Source§impl Debug for ParquetStatisticsPolicy
impl Debug for ParquetStatisticsPolicy
Auto Trait Implementations§
impl Freeze for ParquetStatisticsPolicy
impl RefUnwindSafe for ParquetStatisticsPolicy
impl Send for ParquetStatisticsPolicy
impl Sync for ParquetStatisticsPolicy
impl Unpin for ParquetStatisticsPolicy
impl UnsafeUnpin for ParquetStatisticsPolicy
impl UnwindSafe for ParquetStatisticsPolicy
Blanket Implementations§
impl<T> Allocation for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more