pub fn result<T: serde::de::DeserializeOwned>(&self) -> Result<T, Error> {
        if let Some(ref e) = self.error {
            return Err(Error::Rpc(e.clone()));
        }

        serde_json::from_value(self.result.clone().unwrap_or(serde_json::Value::Null))
            .map_err(Error::Json)
    }
/// Extract the result from a response
Extract the result from a response
Extract the result from a response
pub fn result<T: serde::de::DeserializeOwned>(&self) -> Result<T, Error> {
        if let Some(ref e) = self.error {
            return Err(Error::Rpc(e.clone()));
        }
        serde_json::from_value(self.result.clone().unwrap_or(serde_json::Value::Null))
            .map_err(Error::Json)
    }
pub fn result < T : serde :: de :: DeserializeOwned > ( & self ) -> Result < T , Error > { if let Some ( ref e ) = self . error { return Err ( Error :: Rpc ( e . clone ( ) ) ) ; } serde_json :: from_value ( self . result . clone ( ) . unwrap_or ( serde_json :: Value :: Null ) ) . map_err ( Error :: Json ) }
Extract the result from a response
Extract the result from a response
&self
&self