[−][src]Struct fibers_http_server::metrics::WithMetrics
A handler for granting the metrics collection functionality to the inner handler H
.
Methods
impl<H: HandleRequest> WithMetrics<H>
[src]
pub fn new(inner: H) -> Self
[src]
Makes a new WithMetrics
instance.
pub fn with_metrics(inner: H, metric_builder: MetricBuilder) -> Self
[src]
Makes a new WithMetrics
instance with the given MetricBuilder
.
pub fn metrics(&self) -> &HandlerMetrics
[src]
Returns the metrics of the handler.
Trait Implementations
impl<H: HandleRequest> HandleRequest for WithMetrics<H>
[src]
const METHOD: &'static str
[src]
const PATH: &'static str
[src]
type ReqBody = H::ReqBody
The type of the request bodies.
type ResBody = H::ResBody
The type of the response bodies.
type Decoder = H::Decoder
Request body decoder.
type Encoder = H::Encoder
Response body encoder.
type Reply = Time<H>
Future
that represents reply to a request.
fn handle_request(&self, req: Req<Self::ReqBody>) -> Self::Reply
[src]
fn handle_request_head(&self, req: &Req<()>) -> Option<Res<Self::ResBody>>
[src]
fn handle_decoding_error(
&self,
req: Req<()>,
error: &Error
) -> Option<Res<Self::ResBody>>
[src]
&self,
req: Req<()>,
error: &Error
) -> Option<Res<Self::ResBody>>
impl<H: Debug> Debug for WithMetrics<H>
[src]
Auto Trait Implementations
impl<H> Unpin for WithMetrics<H> where
H: Unpin,
H: Unpin,
impl<H> Send for WithMetrics<H> where
H: Send,
H: Send,
impl<H> Sync for WithMetrics<H> where
H: Sync,
H: Sync,
impl<H> RefUnwindSafe for WithMetrics<H> where
H: RefUnwindSafe,
H: RefUnwindSafe,
impl<H> UnwindSafe for WithMetrics<H> where
H: UnwindSafe,
H: UnwindSafe,
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> SendSyncUnwindSafe for T where
T: Send + Sync + UnwindSafe + ?Sized,
[src]
T: Send + Sync + UnwindSafe + ?Sized,