pub struct FileMetaData {
version: i32,
num_rows: i64,
created_by: Option<String>,
key_value_metadata: Option<Vec<KeyValue>>,
schema_descr: SchemaDescPtr,
column_orders: Option<Vec<ColumnOrder>>,
}
Expand description
File level metadata for a Parquet file.
Includes the version of the file, metadata, number of rows, schema, and column orders
Fields§
§version: i32
§num_rows: i64
§created_by: Option<String>
§key_value_metadata: Option<Vec<KeyValue>>
§schema_descr: SchemaDescPtr
§column_orders: Option<Vec<ColumnOrder>>
Implementations§
Source§impl FileMetaData
impl FileMetaData
Sourcepub fn new(
version: i32,
num_rows: i64,
created_by: Option<String>,
key_value_metadata: Option<Vec<KeyValue>>,
schema_descr: SchemaDescPtr,
column_orders: Option<Vec<ColumnOrder>>,
) -> Self
pub fn new( version: i32, num_rows: i64, created_by: Option<String>, key_value_metadata: Option<Vec<KeyValue>>, schema_descr: SchemaDescPtr, column_orders: Option<Vec<ColumnOrder>>, ) -> Self
Creates new file metadata.
Sourcepub fn created_by(&self) -> Option<&str>
pub fn created_by(&self) -> Option<&str>
String message for application that wrote this file.
This should have the following format:
<application> version <application version> (build <application build hash>)
.
parquet-mr version 1.8.0 (build 0fda28af84b9746396014ad6a415b90592a98b3b)
Sourcepub fn key_value_metadata(&self) -> Option<&Vec<KeyValue>>
pub fn key_value_metadata(&self) -> Option<&Vec<KeyValue>>
Returns key_value_metadata of this file.
Sourcepub fn schema(&self) -> &SchemaType
pub fn schema(&self) -> &SchemaType
Returns Parquet Type
that describes schema in this file.
Sourcepub fn schema_descr(&self) -> &SchemaDescriptor
pub fn schema_descr(&self) -> &SchemaDescriptor
Returns a reference to schema descriptor.
Sourcepub fn schema_descr_ptr(&self) -> SchemaDescPtr
pub fn schema_descr_ptr(&self) -> SchemaDescPtr
Returns reference counted clone for schema descriptor.
Sourcepub fn column_orders(&self) -> Option<&Vec<ColumnOrder>>
pub fn column_orders(&self) -> Option<&Vec<ColumnOrder>>
Column (sort) order used for min
and max
values of each column in this file.
Each column order corresponds to one column, determined by its position in the list, matching the position of the column in the schema.
When None
is returned, there are no column orders available, and each column
should be assumed to have undefined (legacy) column order.
Sourcepub fn column_order(&self, i: usize) -> ColumnOrder
pub fn column_order(&self, i: usize) -> ColumnOrder
Returns column order for i
th column in this file.
If column orders are not available, returns undefined (legacy) column order.
Trait Implementations§
Source§impl Clone for FileMetaData
impl Clone for FileMetaData
Source§fn clone(&self) -> FileMetaData
fn clone(&self) -> FileMetaData
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for FileMetaData
impl Debug for FileMetaData
Source§impl HeapSize for FileMetaData
impl HeapSize for FileMetaData
Source§impl PartialEq for FileMetaData
impl PartialEq for FileMetaData
impl StructuralPartialEq for FileMetaData
Auto Trait Implementations§
impl Freeze for FileMetaData
impl RefUnwindSafe for FileMetaData
impl Send for FileMetaData
impl Sync for FileMetaData
impl Unpin for FileMetaData
impl UnwindSafe for FileMetaData
Blanket Implementations§
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more