/// Perform a single request and streaming response
Perform a single request and streaming response
Perform a single request and streaming response
pub async fn server_streaming<T, M, R>(&mut self, request: T, method: M) -> Result<ClientStreaming<R>, RpcError>
    where
        T: prost::Message,
        R: prost::Message + Default,
        M: Into<RpcMethod>,
    {
        let req_bytes = request.to_encoded_bytes();
        let request = BaseRequest::new(method.into(), req_bytes.into());
        let resp = self.call_inner(request).await?;
        Ok(ClientStreaming::new(resp))
    }
pub async fn server_streaming < T , M , R > ( & mut self , request : T , method : M ) -> Result < ClientStreaming < R > , RpcError > where T : prost :: Message , R : prost :: Message + Default , M : Into < RpcMethod > , { let req_bytes = request . to_encoded_bytes ( ) ; let request = BaseRequest :: new ( method . into ( ) , req_bytes . into ( ) ) ; let resp = self . call_inner ( request ) . await ? ; Ok ( ClientStreaming :: new ( resp ) ) }
Perform a single request and streaming response
Perform a single request and streaming response
&mut self
request
T
method
M