mirror of https://github.com/fafhrd91/actix-web
update handler docs
This commit is contained in:
parent
e46d27ae1f
commit
bacc5f5e3e
|
@ -14,8 +14,10 @@ use crate::request::HttpRequest;
|
|||
use crate::responder::Responder;
|
||||
use crate::service::{ServiceRequest, ServiceResponse};
|
||||
|
||||
/// Async handler converter factory
|
||||
///
|
||||
/// A request handler is an async function that accepts zero or more parameters that can be
|
||||
/// extracted from a request (ie, [`impl FromRequest`](crate::FromRequest)) and returns a type that can be converted into
|
||||
/// an [`HttpResponse`](crate::HttpResponse) (ie, [`impl Responder`](crate::Responder)).
|
||||
///
|
||||
/// If you got the error `the trait Handler<_, _, _> is not implemented`, then your function is not
|
||||
/// a valid handler. See [Request Handlers](https://actix.rs/docs/handlers/) for more information.
|
||||
pub trait Handler<T, R, O>: Clone + 'static
|
||||
|
|
Loading…
Reference in New Issue