pub struct SchemaDescriptor { /* private fields */ }Available on crate feature
io_parquet only.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 duplicate 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
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> ⓘ
Converts
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> ⓘ
Converts
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