pub enum StixValue {
Null,
Bool(bool),
Integer(i64),
Float(f64),
String(String),
List(Vec<StixValue>),
Object(BTreeMap<String, StixValue>),
}Expand description
A dynamic STIX property value.
STIX timestamps, hex, and binary are carried as StixValue::String at this
layer; higher layers interpret them. Integers and floats are kept distinct so
numeric comparisons behave correctly.
Variants§
Null
JSON null.
Bool(bool)
A boolean value.
Integer(i64)
A signed integer value.
Float(f64)
A floating-point value.
String(String)
A string value (also carries timestamps, hex, and binary at this layer).
List(Vec<StixValue>)
An ordered list of values.
Object(BTreeMap<String, StixValue>)
A key-ordered map of property names to values.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for StixValue
impl<'de> Deserialize<'de> for StixValue
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for StixValue
Auto Trait Implementations§
impl Freeze for StixValue
impl RefUnwindSafe for StixValue
impl Send for StixValue
impl Sync for StixValue
impl Unpin for StixValue
impl UnsafeUnpin for StixValue
impl UnwindSafe for StixValue
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