Struct prometheus_client::encoding::DescriptorEncoder
source · pub struct DescriptorEncoder<'a>(/* private fields */);
Expand description
Encoder for a Metric Descriptor.
Implementations§
source§impl DescriptorEncoder<'_>
impl DescriptorEncoder<'_>
sourcepub fn encode_descriptor<'s>(
&'s mut self,
name: &'s str,
help: &str,
unit: Option<&'s Unit>,
metric_type: MetricType
) -> Result<MetricEncoder<'s>, Error>
pub fn encode_descriptor<'s>( &'s mut self, name: &'s str, help: &str, unit: Option<&'s Unit>, metric_type: MetricType ) -> Result<MetricEncoder<'s>, Error>
Encode a descriptor.
Trait Implementations§
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for DescriptorEncoder<'a>
impl<'a> !Send for DescriptorEncoder<'a>
impl<'a> !Sync for DescriptorEncoder<'a>
impl<'a> Unpin for DescriptorEncoder<'a>
impl<'a> !UnwindSafe for DescriptorEncoder<'a>
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