Function viz::prelude::only [−][src]
pub fn only<H, A, const S: usize>(methods: [Method; S], h: H) -> Route where
A: Extract,
H: Handler<A>,
<A as Extract>::Error: Into<Response>,
<H as Handler<A>>::Output: Into<Response>,
<H as Handler<A>>::Future: 'static,
<H as Handler<A>>::Future: Future,
<H as Handler<A>>::Future: Send,
Endpoint<H, A>: for<'m> Handle<'m, Context>,
<<H as Handler<A>>::Future as Future>::Output == <H as Handler<A>>::Output,
<Endpoint<H, A> as Handle<'m, Context>>::Output == Result<Response, Error>,
Expand description
Appends a route, only handle HTTP verbs