Enum smartnoise_validator::base::Value[][src]

pub enum Value {
    Array(Array),
    Dataframe(IndexMap<IndexKey, Value>),
    Partitions(IndexMap<IndexKey, Value>),
    Jagged(Jagged),
    Function(Function),
}

The universal data representation.

Arguments to components are hash-maps of Value and the result of a component is a Value. The Value is also used in the validator for public arguments.

The Value has a one-to-one mapping to a protobuf Value.

Components unwrap arguments into more granular types, like ndarray::Array1, run a computation, and then repackage the result back into a Value.

Variants

Array(Array)

An arbitrary-dimensional homogeneously typed array

Dataframe(IndexMap<IndexKey, Value>)

An index-map, where the keys are enum-typed and the values are of type Value

Partitions(IndexMap<IndexKey, Value>)

An index-map, where the keys are enum-typed and the values are of type Value

Jagged(Jagged)

A 2D homogeneously typed matrix, where the columns may be unknown and the column lengths may be inconsistent

Function(Function)

An arbitrary function expressed in the graph language

Implementations

impl Value[src]

pub fn array(self) -> Result<Array>[src]

Retrieve an Array from a Value, assuming the Value contains an Array

pub fn ref_array(&self) -> Result<&Array>[src]

pub fn jagged(self) -> Result<Jagged>[src]

Retrieve Jagged from a Value, assuming the Value contains Jagged

pub fn ref_jagged(&self) -> Result<&Jagged>[src]

pub fn dataframe(self) -> Result<IndexMap<IndexKey, Value>>[src]

pub fn partitions(self) -> Result<IndexMap<IndexKey, Value>>[src]

pub fn ref_partitions(&self) -> Result<&IndexMap<IndexKey, Value>>[src]

pub fn function(self) -> Result<Function>[src]

pub fn from_index_key(key: IndexKey) -> Result<Self>[src]

Trait Implementations

impl Clone for Value[src]

impl Debug for Value[src]

impl<T> From<ArrayBase<OwnedRepr<String>, Dim<T>>> for Value where
    Dim<T>: Dimension
[src]

impl<T> From<ArrayBase<OwnedRepr<bool>, Dim<T>>> for Value where
    Dim<T>: Dimension
[src]

impl<T> From<ArrayBase<OwnedRepr<f64>, Dim<T>>> for Value where
    Dim<T>: Dimension
[src]

impl<T> From<ArrayBase<OwnedRepr<i64>, Dim<T>>> for Value where
    Dim<T>: Dimension
[src]

impl From<String> for Value[src]

impl From<bool> for Value[src]

impl From<f64> for Value[src]

impl From<i64> for Value[src]

impl PartialEq<Value> for Value[src]

Auto Trait Implementations

impl RefUnwindSafe for Value

impl Send for Value

impl Sync for Value

impl Unpin for Value

impl UnwindSafe for Value

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]