Struct opentelemetry::InstrumentationScope
source · #[non_exhaustive]pub struct InstrumentationScope { /* private fields */ }
Expand description
Information about a library or crate providing instrumentation.
An instrumentation scope should be named to follow any naming conventions of the instrumented library (e.g. ‘middleware’ for a web framework).
See the instrumentation libraries spec for more information.
Implementations§
source§impl InstrumentationScope
impl InstrumentationScope
sourcepub fn builder<T: Into<Cow<'static, str>>>(
name: T,
) -> InstrumentationScopeBuilder
pub fn builder<T: Into<Cow<'static, str>>>( name: T, ) -> InstrumentationScopeBuilder
Create a new builder to create an InstrumentationScope
sourcepub fn schema_url(&self) -> Option<&str>
pub fn schema_url(&self) -> Option<&str>
Returns the Schema URL used by this library.
sourcepub fn attributes(&self) -> impl Iterator<Item = &KeyValue>
pub fn attributes(&self) -> impl Iterator<Item = &KeyValue>
Returns the instrumentation scope attributes to associate with emitted telemetry.
Trait Implementations§
source§impl Clone for InstrumentationScope
impl Clone for InstrumentationScope
source§fn clone(&self) -> InstrumentationScope
fn clone(&self) -> InstrumentationScope
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for InstrumentationScope
impl Debug for InstrumentationScope
source§impl Default for InstrumentationScope
impl Default for InstrumentationScope
source§fn default() -> InstrumentationScope
fn default() -> InstrumentationScope
Returns the “default value” for a type. Read more
source§impl Hash for InstrumentationScope
impl Hash for InstrumentationScope
source§impl PartialEq for InstrumentationScope
impl PartialEq for InstrumentationScope
impl Eq for InstrumentationScope
Auto Trait Implementations§
impl Freeze for InstrumentationScope
impl RefUnwindSafe for InstrumentationScope
impl Send for InstrumentationScope
impl Sync for InstrumentationScope
impl Unpin for InstrumentationScope
impl UnwindSafe for InstrumentationScope
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)