Struct mz_persist_types::dyn_struct::DynStructCol
source · pub struct DynStructCol {
pub(crate) len: usize,
pub(crate) cfg: DynStructCfg,
pub(crate) validity: Option<NullBuffer>,
pub(crate) cols: Vec<DynColumnRef>,
}
Expand description
A crate::columnar::ColumnGet impl for DynStruct.
Fields§
§len: usize
§cfg: DynStructCfg
§validity: Option<NullBuffer>
§cols: Vec<DynColumnRef>
Implementations§
source§impl DynStructCol
impl DynStructCol
pub(crate) fn empty(cfg: DynStructCfg) -> Self
fn cols(&self) -> impl Iterator<Item = (&str, &StatsFn, &DynColumnRef)>
sourcepub fn as_ref(&self) -> ColumnsRef
pub fn as_ref(&self) -> ColumnsRef
Explodes this non-optional struct column into its component fields.
Panics if this struct is optional.
sourcepub fn as_opt_ref(&self) -> ColumnsRef<ValidityRef>
pub fn as_opt_ref(&self) -> ColumnsRef<ValidityRef>
Explodes this optional struct column into its component fields and validity.
If the column is actually non-option, succeeds and acts as if every value is a Some.
pub(crate) fn stats( &self, validity: ValidityRef, ) -> Result<OptionStats<StructStats>, String>
pub(crate) fn to_arrow_struct(&self) -> Option<StructArray>
sourcepub fn from_arrow(cfg: DynStructCfg, array: &dyn Array) -> Result<Self, String>
pub fn from_arrow(cfg: DynStructCfg, array: &dyn Array) -> Result<Self, String>
Create a DynStructCol
from an arrow::array::Array
.
pub(crate) fn validate(&self) -> Result<(), String>
Trait Implementations§
source§impl ColumnGet<DynStruct> for DynStructCol
impl ColumnGet<DynStruct> for DynStructCol
source§fn get<'a>(&'a self, idx: usize) -> DynStructRef<'a>
fn get<'a>(&'a self, idx: usize) -> DynStructRef<'a>
Retrieves the value at index.
source§impl ColumnRef<DynStructCfg> for DynStructCol
impl ColumnRef<DynStructCfg> for DynStructCol
source§fn cfg(&self) -> &DynStructCfg
fn cfg(&self) -> &DynStructCfg
Returns the super::ColumnCfg for this column.
source§fn from_arrow(cfg: &DynStructCfg, array: &dyn Array) -> Result<Self, String>
fn from_arrow(cfg: &DynStructCfg, array: &dyn Array) -> Result<Self, String>
Constructs the column from an
arrow
Array.source§impl Debug for DynStructCol
impl Debug for DynStructCol
source§impl From<DynStructMut> for DynStructCol
impl From<DynStructMut> for DynStructCol
source§fn from(value: DynStructMut) -> Self
fn from(value: DynStructMut) -> Self
Converts to this type from the input type.
source§impl StatsFrom<DynStructCol> for OptionStats<StructStats>
impl StatsFrom<DynStructCol> for OptionStats<StructStats>
source§fn stats_from(col: &DynStructCol, validity: ValidityRef) -> Self
fn stats_from(col: &DynStructCol, validity: ValidityRef) -> Self
Computes statistics from a column of data. Read more
source§impl StatsFrom<DynStructCol> for StructStats
impl StatsFrom<DynStructCol> for StructStats
source§fn stats_from(col: &DynStructCol, validity: ValidityRef) -> Self
fn stats_from(col: &DynStructCol, validity: ValidityRef) -> Self
Computes statistics from a column of data. Read more
Auto Trait Implementations§
impl Freeze for DynStructCol
impl !RefUnwindSafe for DynStructCol
impl Send for DynStructCol
impl Sync for DynStructCol
impl Unpin for DynStructCol
impl !UnwindSafe for DynStructCol
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> FutureExt for T
impl<T> FutureExt for T
source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request
source§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<P, R> ProtoType<R> for Pwhere
R: RustType<P>,
impl<P, R> ProtoType<R> for Pwhere
R: RustType<P>,
source§fn into_rust(self) -> Result<R, TryFromProtoError>
fn into_rust(self) -> Result<R, TryFromProtoError>
See
RustType::from_proto
.source§fn from_rust(rust: &R) -> P
fn from_rust(rust: &R) -> P
See
RustType::into_proto
.