Trait glean_core::metrics::MetricType[][src]

pub trait MetricType {
    fn meta(&self) -> &CommonMetricData;
fn meta_mut(&mut self) -> &mut CommonMetricData; fn should_record(&self, glean: &Glean) -> bool { ... } }

A MetricType describes common behavior across all metrics.

Required methods

fn meta(&self) -> &CommonMetricData[src]

Access the stored metadata

fn meta_mut(&mut self) -> &mut CommonMetricData[src]

Access the stored metadata mutable

Loading content...

Provided methods

fn should_record(&self, glean: &Glean) -> bool[src]

Whether this metric should currently be recorded

This depends on the metrics own state, as determined by its metadata, and whether upload is enabled on the Glean object.

Loading content...

Implementors

impl MetricType for BooleanMetric[src]

impl MetricType for CounterMetric[src]

impl MetricType for CustomDistributionMetric[src]

impl MetricType for DatetimeMetric[src]

impl MetricType for EventMetric[src]

impl MetricType for JweMetric[src]

impl MetricType for MemoryDistributionMetric[src]

impl MetricType for QuantityMetric[src]

impl MetricType for StringListMetric[src]

impl MetricType for StringMetric[src]

impl MetricType for TimespanMetric[src]

impl MetricType for TimingDistributionMetric[src]

impl MetricType for UuidMetric[src]

Loading content...