[][src]Struct glean::private::LabeledMetric

pub struct LabeledMetric<T: AllowLabeled>(_);

This implements the specific facing API for recording labeled metrics.

Instances of this type are automatically generated by the parser at build time, allowing developers to record values that were previously registered in the metrics.yaml file. Unlike most metric types, LabeledMetric does not have its own corresponding storage, but records metrics for the underlying metric type T in the storage for that type.

Implementations

impl<T> LabeledMetric<T> where
    T: AllowLabeled
[src]

pub fn new(meta: CommonMetricData, labels: Option<Vec<String>>) -> Self[src]

The public constructor used by automatically generated metrics.

impl<T> LabeledMetric<T> where
    T: AllowLabeled + Clone
[src]

pub fn get(&self, __arg1: &str) -> T[src]

pub fn test_get_num_recorded_errors<'a, S: Into<Option<&'a str>>>(
    &self,
    __arg1: ErrorType,
    __arg2: S
) -> i32
[src]

Trait Implementations

impl<T: Clone + AllowLabeled> Clone for LabeledMetric<T> where
    T::Inner: Clone
[src]

impl<T> Labeled<T> for LabeledMetric<T> where
    T: AllowLabeled + Clone
[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for LabeledMetric<T> where
    <T as Sealed>::Inner: RefUnwindSafe
[src]

impl<T> Send for LabeledMetric<T> where
    <T as Sealed>::Inner: Send + Sync
[src]

impl<T> Sync for LabeledMetric<T> where
    <T as Sealed>::Inner: Send + Sync
[src]

impl<T> Unpin for LabeledMetric<T>[src]

impl<T> UnwindSafe for LabeledMetric<T> where
    <T as Sealed>::Inner: RefUnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,