mirror of
https://github.com/fafhrd91/actix-net
synced 2025-03-20 16:05:18 +01:00
impl Clone for TakeItem and TakeItemService
This commit is contained in:
parent
dc19a9f862
commit
6c25becd3f
@ -103,6 +103,12 @@ impl<T> TakeItem<T> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl<T> Clone for TakeItem<T> {
|
||||||
|
fn clone(&self) -> TakeItem<T> {
|
||||||
|
TakeItem { _t: PhantomData }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
impl<T: Stream> NewService for TakeItem<T> {
|
impl<T: Stream> NewService for TakeItem<T> {
|
||||||
type Request = T;
|
type Request = T;
|
||||||
type Response = (Option<T::Item>, T);
|
type Response = (Option<T::Item>, T);
|
||||||
@ -121,6 +127,12 @@ pub struct TakeItemService<T> {
|
|||||||
_t: PhantomData<T>,
|
_t: PhantomData<T>,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl<T> Clone for TakeItemService<T> {
|
||||||
|
fn clone(&self) -> TakeItemService<T> {
|
||||||
|
TakeItemService { _t: PhantomData }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
impl<T: Stream> Service for TakeItemService<T> {
|
impl<T: Stream> Service for TakeItemService<T> {
|
||||||
type Request = T;
|
type Request = T;
|
||||||
type Response = (Option<T::Item>, T);
|
type Response = (Option<T::Item>, T);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user