1
0
mirror of https://github.com/actix/actix-extras.git synced 2025-06-25 09:59:21 +02:00

remove Path and Query from public api

This commit is contained in:
Nikolay Kim
2018-03-26 18:18:38 -07:00
parent 052d5f0bc5
commit 8fff2c7595
6 changed files with 84 additions and 28 deletions

View File

@ -5,7 +5,7 @@ and [`ResponseError` trait](../actix_web/error/trait.ResponseError.html)
for handling handler's errors.
Any error that implements `ResponseError` trait can be returned as error value.
*Handler* can return *Result* object, actix by default provides
`Responder` implementation for compatible result object. Here is implementation
`Responder` implementation for compatible result types. Here is implementation
definition:
```rust,ignore
@ -64,7 +64,7 @@ fn index(req: HttpRequest) -> Result<&'static str, MyError> {
# }
```
In this example *index* handler will always return *500* response. But it is easy
In this example *index* handler always returns *500* response. But it is easy
to return different responses for different type of errors.
```rust
@ -109,7 +109,7 @@ fn index(req: HttpRequest) -> Result<&'static str, MyError> {
## Error helpers
Actix provides set of error helper types. It is possible to use them to generate
specific error responses. We can use helper types for first example with custom error.
specific error responses. We can use helper types for the first example with custom error.
```rust
# extern crate actix_web;