pub struct SpanData {
pub other: Object<Value>,
}Expand description
Arbitrary additional data on a span.
Besides arbitrary user data, this type also contains SDK-provided fields used by the product (see https://develop.sentry.dev/sdk/performance/span-data-conventions/).
Fields§
§other: Object<Value>Other fields in span.data.
Implementations§
Source§impl SpanData
impl SpanData
Sourcepub fn get(&self, key: &str) -> Option<&Annotated<Value>>
pub fn get(&self, key: &str) -> Option<&Annotated<Value>>
Returns an annotated attribute from span data.
Sourcepub fn get_value(&self, key: &str) -> Option<&Value>
pub fn get_value(&self, key: &str) -> Option<&Value>
Returns an attribute value from span data.
Sourcepub fn insert(&mut self, key: impl Into<String>, value: Annotated<Value>)
pub fn insert(&mut self, key: impl Into<String>, value: Annotated<Value>)
Inserts an annotated attribute into span data.
Sourcepub fn insert_value<T>(&mut self, key: impl Into<String>, value: T)where
T: IntoValue,
pub fn insert_value<T>(&mut self, key: impl Into<String>, value: T)where
T: IntoValue,
Inserts an attribute into span data.
Trait Implementations§
Source§impl FromObjectRef for SpanData
impl FromObjectRef for SpanData
Source§impl IntoObjectRef for SpanData
impl IntoObjectRef for SpanData
Source§impl IntoValue for SpanData
impl IntoValue for SpanData
Source§fn into_value(self) -> Value
fn into_value(self) -> Value
Boxes the meta structure back into a value.
Source§fn serialize_payload<S>(
&self,
__serializer: S,
__behavior: SkipSerialization,
) -> Result<S::Ok, S::Error>where
Self: Sized,
S: Serializer,
fn serialize_payload<S>(
&self,
__serializer: S,
__behavior: SkipSerialization,
) -> Result<S::Ok, S::Error>where
Self: Sized,
S: Serializer,
Efficiently serializes the payload directly.
Source§fn extract_child_meta(&self) -> MetaMapwhere
Self: Sized,
fn extract_child_meta(&self) -> MetaMapwhere
Self: Sized,
Extracts children meta map out of a value.
Source§impl ProcessValue for SpanData
impl ProcessValue for SpanData
Source§fn value_type(&self) -> EnumSet<ValueType>
fn value_type(&self) -> EnumSet<ValueType>
Returns the type of the value.
Source§fn process_value<P>(
&mut self,
__meta: &mut Meta,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
fn process_value<P>(
&mut self,
__meta: &mut Meta,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
Executes a processor on this value.
Source§fn process_child_values<P>(
&mut self,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
fn process_child_values<P>(
&mut self,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
Recurses into children of this value.
impl StructuralPartialEq for SpanData
Auto Trait Implementations§
impl Freeze for SpanData
impl RefUnwindSafe for SpanData
impl Send for SpanData
impl Sync for SpanData
impl Unpin for SpanData
impl UnsafeUnpin for SpanData
impl UnwindSafe for SpanData
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