Trait ValueType

pub trait ValueType: Sized {
    // Required methods
    fn try_from(v: Value) -> Result<Self, ValueTypeErr>;
    fn type_name() -> String;
    fn array_type() -> ArrayType;
    fn column_type() -> ColumnType;

    // Provided methods
    fn unwrap(v: Value) -> Self { ... }
    fn expect(v: Value, msg: &str) -> Self { ... }
}

Required Methods§

Provided Methods§

fn unwrap(v: Value) -> Self

fn expect(v: Value, msg: &str) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

§

impl ValueType for Cow<'_, str>

§

impl ValueType for bool

§

impl ValueType for char

§

impl ValueType for f32

§

impl ValueType for f64

§

impl ValueType for i8

§

impl ValueType for i16

§

impl ValueType for i32

§

impl ValueType for i64

§

impl ValueType for u8

§

impl ValueType for u16

§

impl ValueType for u32

§

impl ValueType for u64

§

impl ValueType for String

§

impl ValueType for Vec<u8>

§

impl<T> ValueType for Option<T>
where T: ValueType + Nullable,

§

impl<T> ValueType for Vec<T>
where T: NotU8 + ValueType,

Implementors§

§

impl ValueType for Value

Source§

impl ValueType for risingwave_meta_model_migration::m20240630_131430_remove_parallel_unit::I32Array

Source§

impl ValueType for risingwave_meta_model_migration::m20250106_072104_fragment_relation::I32Array

§

impl ValueType for BigDecimal

§

impl ValueType for NaiveDate

§

impl ValueType for NaiveDateTime

§

impl ValueType for Decimal

§

impl ValueType for NaiveTime

§

impl ValueType for Date

§

impl ValueType for PrimitiveDateTime

§

impl ValueType for OffsetDateTime

§

impl ValueType for Time

§

impl ValueType for Uuid

§

impl ValueType for DateTime<FixedOffset>

§

impl ValueType for DateTime<Local>

§

impl ValueType for DateTime<Utc>

§

impl ValueType for Braced

§

impl ValueType for Hyphenated

§

impl ValueType for Simple

§

impl ValueType for Urn