pub async fn send_request(&self, request: &Request<'_, '_>) -> Result<Response, Error> {
        let response: Response = self.send_raw(&request).await?;
        if response.jsonrpc != None && response.jsonrpc != Some(From::from("2.0")) {
            return Err(Error::VersionMismatch);
        }
        if response.id != request.id {
            return Err(Error::NonceMismatch);
        }
        Ok(response)
    }
/// Send a request to a client.
Send a request to a client.
Send a request to a client .
pub async fn send_request(&self, request: &Request<'_, '_>) -> Result<Response, Error> {
        let response: Response = self.send_raw(&request).await?;
        if response.jsonrpc != None && response.jsonrpc != Some(From::from("2.0")) {
            return Err(Error::VersionMismatch);
        }
        if response.id != request.id {
            return Err(Error::NonceMismatch);
        }
        Ok(response)
    }
pub async fn send_request ( & self , request : & Request < ' _ , ' _ > ) -> Result < Response , Error > { let response : Response = self . send_raw ( & request ) . await ? ; if response . jsonrpc != None && response . jsonrpc != Some ( From :: from ( " " ) ) { return Err ( Error :: VersionMismatch ) ; } if response . id != request . id { return Err ( Error :: NonceMismatch ) ; } Ok ( response ) }
Send a request to a client.
Send a request to a client .
&self
request
&Request<'_, '_>
&self
request
&Request<'_, '_>