pub struct ItemSchema {
    pub type: MetricType,
    pub name: String,
    pub prefixes: Vec<String>,
    pub labels: Vec<(String, String)>,
}Expand description
Schema information for a single metric item.
Contains metadata about a metric including its type, name, help text, prefixes, and labels.
Fields§
§type: MetricTypeThe type of the metric (Counter, Gauge, etc.)
name: StringThe name of the metric
prefixes: Vec<String>Prefixes to prepend to the metric name
labels: Vec<(String, String)>Labels associated with the metric as key-value pairs
Implementations§
Source§impl ItemSchema
 
impl ItemSchema
Sourcepub fn prefixed_name(&self) -> String
 
pub fn prefixed_name(&self) -> String
Returns the name prefixed with all prefixes.
Trait Implementations§
Source§impl Clone for ItemSchema
 
impl Clone for ItemSchema
Source§fn clone(&self) -> ItemSchema
 
fn clone(&self) -> ItemSchema
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 ItemSchema
 
impl Debug for ItemSchema
Source§impl<'de> Deserialize<'de> for ItemSchema
 
impl<'de> Deserialize<'de> for ItemSchema
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
    __D: Deserializer<'de>,
 
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
    __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ItemSchema
impl RefUnwindSafe for ItemSchema
impl Send for ItemSchema
impl Sync for ItemSchema
impl Unpin for ItemSchema
impl UnwindSafe for ItemSchema
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