pub enum Value {
Show 30 variants
Null,
Bool(bool),
Int64(i64),
Int32(i32),
Int16(i16),
Int8(i8),
UInt64(u64),
UInt32(u32),
UInt16(u16),
UInt8(u8),
Int128(i128),
Double(f64),
Float(f32),
String(String),
Blob(Vec<u8>),
Date(Date),
Timestamp(Timestamp),
TimestampTz(TimestampTZ),
TimestampNs(Timestamp),
TimestampMs(Timestamp),
TimestampSec(Timestamp),
Interval(Interval),
InternalID(InternalID),
UInt128(u128),
Json(Value),
DTime(i64),
Union(String, Box<Value>),
List(Vec<Value>),
Map(Vec<(Value, Value)>),
Struct(Vec<(String, Value)>),
}Expand description
A Akar value — the runtime representation of any data type.
Variants§
Null
Bool(bool)
Int64(i64)
Int32(i32)
Int16(i16)
Int8(i8)
UInt64(u64)
UInt32(u32)
UInt16(u16)
UInt8(u8)
Int128(i128)
Double(f64)
Float(f32)
String(String)
Blob(Vec<u8>)
Date(Date)
Timestamp(Timestamp)
TimestampTz(TimestampTZ)
TimestampNs(Timestamp)
TimestampMs(Timestamp)
TimestampSec(Timestamp)
Interval(Interval)
InternalID(InternalID)
UInt128(u128)
Json(Value)
DTime(i64)
Union(String, Box<Value>)
List(Vec<Value>)
Map(Vec<(Value, Value)>)
Struct(Vec<(String, Value)>)
Implementations§
Source§impl Value
impl Value
Sourcepub fn logical_type(&self) -> LogicalTypeID
pub fn logical_type(&self) -> LogicalTypeID
Get the LogicalTypeID corresponding to this Value.
Sourcepub fn physical_type(&self) -> PhysicalTypeID
pub fn physical_type(&self) -> PhysicalTypeID
Get the PhysicalTypeID for this Value’s logical type.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Value
impl<'de> Deserialize<'de> for Value
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Value, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Value, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<InternalID> for Value
impl From<InternalID> for Value
Source§fn from(v: InternalID) -> Value
fn from(v: InternalID) -> Value
Converts to this type from the input type.
Source§impl Serialize for Value
impl Serialize for Value
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for Value
Auto Trait Implementations§
impl Freeze for Value
impl RefUnwindSafe for Value
impl Send for Value
impl Sync for Value
impl Unpin for Value
impl UnsafeUnpin for Value
impl UnwindSafe for Value
Blanket Implementations§
impl<T> Allocation for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
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