Struct prometheus::HistogramOpts [] [src]

pub struct HistogramOpts {
    pub common_opts: Opts,
    pub buckets: Vec<f64>,
}

HistogramOpts bundles the options for creating a Histogram metric. It is mandatory to set Name and Help to a non-empty string. All other fields are optional and can safely be left at their zero value.

Fields

Methods

impl HistogramOpts
[src]

[src]

new creates a HistogramOpts with the name and help arguments.

[src]

namespace sets the namespace.

[src]

subsystem sets the sub system.

[src]

const_labels sets the const labels.

[src]

const_label adds a const label.

[src]

variable_labels sets the variable labels.

[src]

variable_label adds a variable label.

[src]

fq_name returns the fq_name.

[src]

buckets set the buckets.

Trait Implementations

impl Clone for HistogramOpts
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl From<Opts> for HistogramOpts
[src]

[src]

Performs the conversion.