pub struct SchemaDescriptor { /* private fields */ }
Expand description
A schema descriptor. This encapsulates the top-level schemas for all the columns, as well as all descriptors for all the primitive columns.
Implementations§
source§impl SchemaDescriptor
impl SchemaDescriptor
sourcepub fn new(name: String, fields: Vec<ParquetType>) -> SchemaDescriptor
pub fn new(name: String, fields: Vec<ParquetType>) -> SchemaDescriptor
Creates new schema descriptor from Parquet schema.
sourcepub fn columns(&self) -> &[ColumnDescriptor]
pub fn columns(&self) -> &[ColumnDescriptor]
The ColumnDescriptor
(leafs) of this schema.
Note that, for nested fields, this may contain more entries than the number of fields in the file - e.g. a struct field may have two columns.
sourcepub fn fields(&self) -> &[ParquetType]
pub fn fields(&self) -> &[ParquetType]
The schemas’ fields.
sourcepub fn try_from_message(message: &str) -> Result<SchemaDescriptor, Error>
pub fn try_from_message(message: &str) -> Result<SchemaDescriptor, Error>
Creates a schema from
Trait Implementations§
source§impl Clone for SchemaDescriptor
impl Clone for SchemaDescriptor
source§fn clone(&self) -> SchemaDescriptor
fn clone(&self) -> SchemaDescriptor
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for SchemaDescriptor
impl RefUnwindSafe for SchemaDescriptor
impl Send for SchemaDescriptor
impl Sync for SchemaDescriptor
impl Unpin for SchemaDescriptor
impl UnwindSafe for SchemaDescriptor
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
Mutably borrows from an owned value. Read more