pub struct JsonrpcResponse {
pub jsonrpc: String,
pub id: Value,
pub result: Option<Value>,
pub error: Option<JsonrpcError>,
}Expand description
A JSONRPC response object
Fields§
§jsonrpc: Stringjsonrpc field, MUST be “2.0”
id: ValueIdentifier for this Request, which should match that of the request
result: Option<Value>A result if there is one, or null
error: Option<JsonrpcError>An error if there is one, or null
Trait Implementations§
Source§impl Clone for JsonrpcResponse
impl Clone for JsonrpcResponse
Source§fn clone(&self) -> JsonrpcResponse
fn clone(&self) -> JsonrpcResponse
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for JsonrpcResponse
impl Debug for JsonrpcResponse
Source§impl<'de> Deserialize<'de> for JsonrpcResponse
impl<'de> Deserialize<'de> for JsonrpcResponse
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<(u64, PluginResponse)> for JsonrpcResponse
impl From<(u64, PluginResponse)> for JsonrpcResponse
Source§fn from((id, response): (u64, PluginResponse)) -> JsonrpcResponse
fn from((id, response): (u64, PluginResponse)) -> JsonrpcResponse
Converts to this type from the input type.
Source§impl Serialize for JsonrpcResponse
impl Serialize for JsonrpcResponse
Source§impl TryFrom<JsonrpcResponse> for (u64, PluginResponse)
impl TryFrom<JsonrpcResponse> for (u64, PluginResponse)
Auto Trait Implementations§
impl Freeze for JsonrpcResponse
impl RefUnwindSafe for JsonrpcResponse
impl Send for JsonrpcResponse
impl Sync for JsonrpcResponse
impl Unpin for JsonrpcResponse
impl UnwindSafe for JsonrpcResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more