Struct async_jsonrpc_client::Failure[][src]

pub struct Failure {
    pub jsonrpc: Version,
    pub error: Error,
    pub id: Option<Id>,
}

Represents JSON-RPC 2.0 failure response.

Fields

jsonrpc: Version

A String specifying the version of the JSON-RPC protocol.

error: Error

Failed execution error.

id: Option<Id>

Correlation id.

It MUST be the same as the value of the id member in the Request Object.

If there was an error in detecting the id in the Request object (e.g. Parse error/Invalid Request), it MUST be Null.

Implementations

impl Failure[src]

pub fn new(error: Error, id: Option<Id>) -> Failure[src]

Creates a JSON-RPC 2.0 failure response.

Trait Implementations

impl Clone for Failure[src]

impl Debug for Failure[src]

impl<'de> Deserialize<'de> for Failure[src]

impl Display for Failure[src]

impl Eq for Failure[src]

impl<T> From<Failure> for Response<T>[src]

impl PartialEq<Failure> for Failure[src]

impl Serialize for Failure[src]

impl StructuralEq for Failure[src]

impl StructuralPartialEq for Failure[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.