pub enum Value {
Show 24 variants
Bool(Option<bool>),
TinyInt(Option<i8>),
SmallInt(Option<i16>),
Int(Option<i32>),
BigInt(Option<i64>),
TinyUnsigned(Option<u8>),
SmallUnsigned(Option<u16>),
Unsigned(Option<u32>),
BigUnsigned(Option<u64>),
Float(Option<f32>),
Double(Option<f64>),
String(Option<Box<String>>),
Bytes(Option<Box<Vec<u8>>>),
Json(Option<Box<Json>>),
Date(Option<Box<NaiveDate>>),
Time(Option<Box<NaiveTime>>),
DateTime(Option<Box<NaiveDateTime>>),
DateTimeUtc(Option<Box<DateTime<Utc>>>),
DateTimeLocal(Option<Box<DateTime<Local>>>),
DateTimeWithTimeZone(Option<Box<DateTime<FixedOffset>>>),
Uuid(Option<Box<Uuid>>),
Decimal(Option<Box<Decimal>>),
BigDecimal(Option<Box<BigDecimal>>),
Array(Option<Box<Vec<Value>>>),
}
Expand description
Value variants
We want Value to be exactly 1 pointer sized, so anything larger should be boxed.
Variants
Bool(Option<bool>)
TinyInt(Option<i8>)
SmallInt(Option<i16>)
Int(Option<i32>)
BigInt(Option<i64>)
TinyUnsigned(Option<u8>)
SmallUnsigned(Option<u16>)
Unsigned(Option<u32>)
BigUnsigned(Option<u64>)
Float(Option<f32>)
Double(Option<f64>)
String(Option<Box<String>>)
Bytes(Option<Box<Vec<u8>>>)
Json(Option<Box<Json>>)
This is supported on crate feature
with-json
only.Date(Option<Box<NaiveDate>>)
This is supported on crate feature
with-chrono
only.Time(Option<Box<NaiveTime>>)
This is supported on crate feature
with-chrono
only.DateTime(Option<Box<NaiveDateTime>>)
This is supported on crate feature
with-chrono
only.DateTimeUtc(Option<Box<DateTime<Utc>>>)
This is supported on crate feature
with-chrono
only.DateTimeLocal(Option<Box<DateTime<Local>>>)
This is supported on crate feature
with-chrono
only.DateTimeWithTimeZone(Option<Box<DateTime<FixedOffset>>>)
This is supported on crate feature
with-chrono
only.Uuid(Option<Box<Uuid>>)
This is supported on crate feature
with-uuid
only.Decimal(Option<Box<Decimal>>)
This is supported on crate feature
with-rust_decimal
only.BigDecimal(Option<Box<BigDecimal>>)
This is supported on crate feature
with-bigdecimal
only.Array(Option<Box<Vec<Value>>>)
This is supported on crate feature
postgres-array
only.Implementations
Trait Implementations
Performs the conversion.
Performs the conversion.
Performs the conversion.
Auto Trait Implementations
impl RefUnwindSafe for Value
impl UnwindSafe for Value
Blanket Implementations
Mutably borrows from an owned value. Read more
Returns a reference to self
as a ToSql
trait object.