Trait json_rpc2::futures::Service[][src]

pub trait Service: Send + Sync {
    type Data: Send + Sync;
    fn handle<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        request: &'life1 mut Request,
        ctx: &'life2 Self::Data
    ) -> Pin<Box<dyn Future<Output = Result<Option<Response>>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        'life2: 'async_trait,
        Self: 'async_trait
; }
Expand description

Trait for async services that maybe handle a request.

Only available with the async feature.

Associated Types

Type of the user data for this service.

Required methods

See Service for more information.

Implementors