pub struct PromMetricsServer { /* private fields */ }
Implementations§
Source§impl PromMetricsServer
impl PromMetricsServer
pub fn new(reg: PromMetricRegistry) -> Arc<Self>
pub fn register_fn<T: 'static>( &self, metrics: &Arc<T>, register: impl FnOnce(&'static T, &mut RegisterAction<'_>), )
pub async fn register_async_fn<T: 'static>( &self, metrics: &Arc<T>, register: impl FnOnce(&'static T, &mut RegisterAction<'_>), )
pub fn register<T: RegisterableMetric + 'static>(&self, metrics: &Arc<T>)
pub async fn register_async<T: RegisterableMetric + 'static>( &self, metrics: &Arc<T>, )
pub async fn write<T: Write>(&self, f: &mut T) -> Result<()>
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for PromMetricsServer
impl !RefUnwindSafe for PromMetricsServer
impl Send for PromMetricsServer
impl Sync for PromMetricsServer
impl Unpin for PromMetricsServer
impl !UnwindSafe for PromMetricsServer
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