pub enum Value<'a> {
Bool(bool),
Int64 {
value: i64,
unit: Option<Id>,
},
Float64 {
value: f64,
unit: Option<Id>,
},
Decimal {
exponent: i32,
mantissa: DecimalMantissa<'a>,
unit: Option<Id>,
},
Text {
value: Cow<'a, str>,
language: Option<Id>,
},
Bytes(Cow<'a, [u8]>),
Date {
days: i32,
offset_min: i16,
},
Time {
time_us: i64,
offset_min: i16,
},
Datetime {
epoch_us: i64,
offset_min: i16,
},
Schedule(Cow<'a, str>),
Point {
lon: f64,
lat: f64,
alt: Option<f64>,
},
Embedding {
sub_type: EmbeddingSubType,
dims: usize,
data: Cow<'a, [u8]>,
},
}Expand description
A typed value that can be stored on an entity or relation.
Variants§
Bool(bool)
Boolean value.
Int64
64-bit signed integer with optional unit.
Float64
64-bit IEEE 754 float (NaN not allowed) with optional unit.
Decimal
Arbitrary-precision decimal: value = mantissa * 10^exponent, with optional unit.
Fields
§
mantissa: DecimalMantissa<'a>Text
UTF-8 text with optional language.
Bytes(Cow<'a, [u8]>)
Opaque byte array.
Date
Calendar date (6 bytes: int32 days + int16 offset_min).
Fields
Time
Time of day (8 bytes: int48 time_us + int16 offset_min).
Fields
Datetime
Combined date and time (10 bytes: int64 epoch_us + int16 offset_min).
Fields
Schedule(Cow<'a, str>)
RFC 5545 iCalendar schedule string.
Point
WGS84 geographic coordinate with optional altitude.
Fields
Embedding
Dense vector for semantic similarity search.
Implementations§
Trait Implementations§
impl<'a> StructuralPartialEq for Value<'a>
Auto Trait Implementations§
impl<'a> Freeze for Value<'a>
impl<'a> RefUnwindSafe for Value<'a>
impl<'a> Send for Value<'a>
impl<'a> Sync for Value<'a>
impl<'a> Unpin for Value<'a>
impl<'a> UnwindSafe for Value<'a>
Blanket Implementations§
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