pub struct ServiceBuilder { /* fields omitted */ }
Service
factory in order to configure the properties.
Use it to build a service which can be registered to a server.
pub fn add_unary_handler<Req, Resp, F>( self, method: &Method<Req, Resp>, handler: F ) -> ServiceBuilder where Req: 'static, Resp: 'static, F: FnMut(RpcContext, Req, UnarySink<Resp>) + Send + Clone + 'static, | [src] |
Add a unary RPC call handler.
pub fn add_client_streaming_handler<Req, Resp, F>( self, method: &Method<Req, Resp>, handler: F ) -> ServiceBuilder where Req: 'static, Resp: 'static, F: FnMut(RpcContext, RequestStream<Req>, ClientStreamingSink<Resp>) + Send + Clone + 'static, | [src] |
Add a client streaming RPC call handler.
pub fn add_server_streaming_handler<Req, Resp, F>( self, method: &Method<Req, Resp>, handler: F ) -> ServiceBuilder where Req: 'static, Resp: 'static, F: FnMut(RpcContext, Req, ServerStreamingSink<Resp>) + Send + Clone + 'static, | [src] |
Add a server streaming RPC call handler.
pub fn add_duplex_streaming_handler<Req, Resp, F>( self, method: &Method<Req, Resp>, handler: F ) -> ServiceBuilder where Req: 'static, Resp: 'static, F: FnMut(RpcContext, RequestStream<Req>, DuplexSink<Resp>) + Send + Clone + 'static, | [src] |
Add a duplex streaming RPC call handler.
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static