checkpoint
This commit is contained in:
parent
b23cd1e6e4
commit
5817e03bf3
|
@ -40,4 +40,6 @@
|
|||
/// parameterized by 'a), *not* that the object itself has 'static lifetime.
|
||||
pub type Error = Box<dyn std::error::Error + Send + Sync + 'static>;
|
||||
|
||||
mod peer_set;
|
||||
mod peer_set {
|
||||
mod set;
|
||||
}
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
mod set;
|
|
@ -1,16 +1,6 @@
|
|||
use crate::Error;
|
||||
use std::{fmt::Debug, future::Future, pin::Pin};
|
||||
|
||||
pub trait Discover {
|
||||
type Key;
|
||||
}
|
||||
|
||||
pub trait Service<Request> {
|
||||
type Error;
|
||||
type Future: Future<Output = Result<Response, Self::Error>>;
|
||||
fn call(&mut self, req: Request) -> Self::Future;
|
||||
}
|
||||
|
||||
use crate::Error;
|
||||
pub struct Request;
|
||||
pub struct Response;
|
||||
|
||||
|
@ -33,3 +23,13 @@ where
|
|||
todo!()
|
||||
}
|
||||
}
|
||||
|
||||
pub trait Discover {
|
||||
type Key;
|
||||
}
|
||||
|
||||
pub trait Service<Request> {
|
||||
type Error;
|
||||
type Future: Future<Output = Result<Response, Self::Error>>;
|
||||
fn call(&mut self, req: Request) -> Self::Future;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue