Struct sentry_core::Scope
source · [−]pub struct Scope { /* private fields */ }
Expand description
Holds contextual data for the current scope.
The scope is an object that can be cloned efficiently and stores data that is locally relevant to an event. For instance the scope will hold recorded breadcrumbs and similar information.
The scope can be interacted with in two ways:
- the scope is routinely updated with information by functions such as
add_breadcrumb
which will modify the currently top-most scope. - the topmost scope can also be configured through the
configure_scope
method.
Note that the scope can only be modified but not inspected. Only the client can use the scope to extract information currently.
Implementations
Clear the scope.
By default a scope will inherit all values from the higher scope. In some situations this might not be what a user wants. Calling this method will wipe all data contained within.
Deletes current breadcrumbs from the scope.
Sets the transaction.
Removes a tag.
If the tag is not set, does nothing.
Sets a context for a key.
Removes a context for a key.
Removes a extra.
Add an event processor to the scope.
Applies the contained scoped data to fill an event.
Set the given TransactionOrSpan
as the active span for this scope.
Returns the currently active span.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Scope
impl !UnwindSafe for Scope
Blanket Implementations
Mutably borrows from an owned value. Read more