mirror of https://github.com/fafhrd91/actix-net
update changelog. restric fn_service type a little
This commit is contained in:
parent
4ea4724fa7
commit
6627c6b129
|
@ -1,6 +1,9 @@
|
|||
# Changes
|
||||
|
||||
## Unreleased - 2021-xx-xx
|
||||
* `Router::recognize_mut_checked` take `&self` and return `Option<(&T, ResourceId)>` [#247]
|
||||
|
||||
[#247]: https://github.com/actix/actix-net/pull/247
|
||||
|
||||
|
||||
## 0.2.6 - 2021-01-09
|
||||
|
|
|
@ -1,6 +1,12 @@
|
|||
# Changes
|
||||
|
||||
## Unreleased - 2021-xx-xx
|
||||
* `Service::poll_ready` and `Service::call` take `&self`. [#247]
|
||||
* `apply_fn` and `apply_fn_factory` would take `Fn(Req, &Service)` function type [#247]
|
||||
* `apply_cfg` and `apply_cfg_factory` would take `Fn(Req, &Service)` function type [#247]
|
||||
* `fn_service` module would take `Fn(Req)` function type. [#247]
|
||||
|
||||
[#247]: https://github.com/actix/actix-net/pull/247
|
||||
|
||||
|
||||
## 2.0.0-beta.3 - 2021-01-09
|
||||
|
|
|
@ -103,7 +103,7 @@ where
|
|||
|
||||
pub struct FnService<F, Fut, Req, Res, Err>
|
||||
where
|
||||
F: Fn(Req) -> Fut,
|
||||
F: FnMut(Req) -> Fut,
|
||||
Fut: Future<Output = Result<Res, Err>>,
|
||||
{
|
||||
f: F,
|
||||
|
@ -112,7 +112,7 @@ where
|
|||
|
||||
impl<F, Fut, Req, Res, Err> FnService<F, Fut, Req, Res, Err>
|
||||
where
|
||||
F: Fn(Req) -> Fut,
|
||||
F: FnMut(Req) -> Fut,
|
||||
Fut: Future<Output = Result<Res, Err>>,
|
||||
{
|
||||
pub(crate) fn new(f: F) -> Self {
|
||||
|
@ -122,7 +122,7 @@ where
|
|||
|
||||
impl<F, Fut, Req, Res, Err> Clone for FnService<F, Fut, Req, Res, Err>
|
||||
where
|
||||
F: Fn(Req) -> Fut + Clone,
|
||||
F: FnMut(Req) -> Fut + Clone,
|
||||
Fut: Future<Output = Result<Res, Err>>,
|
||||
{
|
||||
fn clone(&self) -> Self {
|
||||
|
|
|
@ -172,13 +172,13 @@ where
|
|||
factory: I,
|
||||
) -> PipelineFactory<
|
||||
impl ServiceFactory<
|
||||
Req,
|
||||
Response = SF1::Response,
|
||||
Error = SF::Error,
|
||||
Config = SF::Config,
|
||||
InitError = SF::InitError,
|
||||
Service = impl Service<Req, Response = SF1::Response, Error = SF::Error> + Clone,
|
||||
> + Clone,
|
||||
Req,
|
||||
Response = SF1::Response,
|
||||
Error = SF::Error,
|
||||
Config = SF::Config,
|
||||
InitError = SF::InitError,
|
||||
Service = impl Service<Req, Response = SF1::Response, Error = SF::Error> + Clone,
|
||||
> + Clone,
|
||||
Req,
|
||||
>
|
||||
where
|
||||
|
@ -209,13 +209,13 @@ where
|
|||
factory: I,
|
||||
) -> PipelineFactory<
|
||||
impl ServiceFactory<
|
||||
Req,
|
||||
Response = SF1::Response,
|
||||
Error = SF::Error,
|
||||
Config = SF::Config,
|
||||
InitError = SF::InitError,
|
||||
Service = impl Service<Req, Response = SF1::Response, Error = SF::Error> + Clone,
|
||||
> + Clone,
|
||||
Req,
|
||||
Response = SF1::Response,
|
||||
Error = SF::Error,
|
||||
Config = SF::Config,
|
||||
InitError = SF::InitError,
|
||||
Service = impl Service<Req, Response = SF1::Response, Error = SF::Error> + Clone,
|
||||
> + Clone,
|
||||
Req,
|
||||
>
|
||||
where
|
||||
|
|
Loading…
Reference in New Issue