Enum opentelemetry::logs::AnyValue
source · pub enum AnyValue {
Int(i64),
Double(f64),
String(StringValue),
Boolean(bool),
Bytes(Vec<u8, Global>),
ListAny(Vec<AnyValue, Global>),
Map(OrderMap<Key, AnyValue, RandomState>),
}
Available on crate feature
logs
only.Expand description
Value types for representing arbitrary values in a log record.
Variants§
Int(i64)
An integer value
Double(f64)
A double value
String(StringValue)
A string value
Boolean(bool)
A boolean value
Bytes(Vec<u8, Global>)
A byte array
ListAny(Vec<AnyValue, Global>)
An array of Any
values
Map(OrderMap<Key, AnyValue, RandomState>)
A map of string keys to Any
values, arbitrarily nested.
Trait Implementations§
source§impl From<StringValue> for AnyValue
impl From<StringValue> for AnyValue
source§fn from(val: StringValue) -> AnyValue
fn from(val: StringValue) -> AnyValue
Converts to this type from the input type.
source§impl<K, V> FromIterator<(K, V)> for AnyValuewhere
K: Into<Key>,
V: Into<AnyValue>,
impl<K, V> FromIterator<(K, V)> for AnyValuewhere K: Into<Key>, V: Into<AnyValue>,
source§fn from_iter<I>(iter: I) -> AnyValuewhere
I: IntoIterator<Item = (K, V)>,
fn from_iter<I>(iter: I) -> AnyValuewhere I: IntoIterator<Item = (K, V)>,
Creates an AnyValue::Map
value from a sequence of key-value pairs
that can be converted into a Key
and AnyValue
respectively.
source§impl<T> FromIterator<T> for AnyValuewhere
T: Into<AnyValue>,
impl<T> FromIterator<T> for AnyValuewhere T: Into<AnyValue>,
source§fn from_iter<I>(iter: I) -> AnyValuewhere
I: IntoIterator<Item = T>,
fn from_iter<I>(iter: I) -> AnyValuewhere I: IntoIterator<Item = T>,
Creates an AnyValue::ListAny
value from a sequence of Into<AnyValue>
values.
Auto Trait Implementations§
impl RefUnwindSafe for AnyValue
impl Send for AnyValue
impl Sync for AnyValue
impl Unpin for AnyValue
impl UnwindSafe for AnyValue
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