Struct StatsSetRef

Source
pub struct StatsSetRef<'a> { /* private fields */ }
Expand description

Reference to an array’s StatsSet. Can be used to get and mutate the underlying stats.

Constructed by calling ArrayStats::to_ref.

Implementations§

Source§

impl StatsSetRef<'_>

Source

pub fn set_iter(&self, iter: StatsSetIntoIter)

Source

pub fn inherit(&self, parent_stats: StatsSetRef<'_>)

Source

pub fn to_owned(&self) -> StatsSet

Source

pub fn into_iter(&self) -> StatsSetIntoIter

Source

pub fn compute_stat(&self, stat: Stat) -> VortexResult<Option<ScalarValue>>

Source

pub fn compute_all(&self, stats: &[Stat]) -> VortexResult<StatsSet>

Source§

impl StatsSetRef<'_>

Source

pub fn get_as<U: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>>( &self, stat: Stat, ) -> Option<Precision<U>>

Source

pub fn get_as_bound<S, U>(&self) -> Option<S::Bound>
where S: StatType<U>, U: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>,

Source

pub fn compute_as<U: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>>( &self, stat: Stat, ) -> Option<U>

Source

pub fn set(&self, stat: Stat, value: Precision<ScalarValue>)

Source

pub fn clear(&self, stat: Stat)

Source

pub fn retain(&self, stats: &[Stat])

Source

pub fn compute_min<U: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>>( &self, ) -> Option<U>

Source

pub fn compute_max<U: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>>( &self, ) -> Option<U>

Source

pub fn compute_is_sorted(&self) -> Option<bool>

Source

pub fn compute_is_strict_sorted(&self) -> Option<bool>

Source

pub fn compute_is_constant(&self) -> Option<bool>

Source

pub fn compute_null_count(&self) -> Option<usize>

Source

pub fn compute_uncompressed_size_in_bytes(&self) -> Option<usize>

Trait Implementations§

Source§

impl StatsProvider for StatsSetRef<'_>

Source§

fn get(&self, stat: Stat) -> Option<Precision<ScalarValue>>

Source§

fn len(&self) -> usize

Count of stored stats with known values.
Source§

fn is_empty(&self) -> bool

Predicate equivalent to a len of zero.

Auto Trait Implementations§

§

impl<'a> Freeze for StatsSetRef<'a>

§

impl<'a> !RefUnwindSafe for StatsSetRef<'a>

§

impl<'a> Send for StatsSetRef<'a>

§

impl<'a> Sync for StatsSetRef<'a>

§

impl<'a> Unpin for StatsSetRef<'a>

§

impl<'a> !UnwindSafe for StatsSetRef<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> Pointee for T

Source§

type Metadata = ()

The metadata type for pointers and references to this type.
Source§

impl<S> StatsProviderExt for S
where S: StatsProvider,

Source§

fn get_scalar(&self, stat: Stat, dtype: &DType) -> Option<Precision<Scalar>>

Source§

fn get_scalar_bound<S: StatType<Scalar>>( &self, dtype: &DType, ) -> Option<S::Bound>

Source§

fn get_as<T: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>>( &self, stat: Stat, ) -> Option<Precision<T>>

Source§

fn get_as_bound<S, U>(&self) -> Option<S::Bound>
where S: StatType<U>, U: for<'a> TryFrom<&'a ScalarValue, Error = VortexError>,

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> ErasedDestructor for T
where T: 'static,