Trait wrpc_transport::serve::ServeExt

source ·
pub trait ServeExt: Serve {
    // Provided method
    fn serve_values<Params, Results>(
        &self,
        instance: &str,
        func: &str,
        paths: impl Into<Arc<[Box<[Option<usize>]>]>> + Send,
    ) -> impl Future<Output = Result<impl Stream<Item = Result<(Self::Context, Params, Option<impl Future<Output = Result<()>> + Send + Unpin + 'static>, impl FnOnce(Results) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'static>> + Send + 'static)>> + Send + 'static>> + Send
       where Params: TupleDecode<Self::Incoming> + Send + 'static,
             Results: TupleEncode<Self::Outgoing> + Send + 'static,
             <Params::Decoder as Decoder>::Error: Error + Send + Sync + 'static,
             <Results::Encoder as Encoder<Results>>::Error: Error + Send + Sync + 'static { ... }
}
Expand description

Extension trait for Serve

Provided Methods§

source

fn serve_values<Params, Results>( &self, instance: &str, func: &str, paths: impl Into<Arc<[Box<[Option<usize>]>]>> + Send, ) -> impl Future<Output = Result<impl Stream<Item = Result<(Self::Context, Params, Option<impl Future<Output = Result<()>> + Send + Unpin + 'static>, impl FnOnce(Results) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'static>> + Send + 'static)>> + Send + 'static>> + Send
where Params: TupleDecode<Self::Incoming> + Send + 'static, Results: TupleEncode<Self::Outgoing> + Send + 'static, <Params::Decoder as Decoder>::Error: Error + Send + Sync + 'static, <Results::Encoder as Encoder<Results>>::Error: Error + Send + Sync + 'static,

Serve function func from instance instance using typed Params and Results

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<T: Serve> ServeExt for T