pub struct JsonrpcErrorResponse {
pub error: RpcError,
pub id: Option<RequestId>,
/* private fields */
}Expand description
A response to a request that indicates an error occurred.
JSON schema
{
"description": "A response to a request that indicates an error occurred.",
"type": "object",
"required": [
"error",
"jsonrpc"
],
"properties": {
"error": {
"$ref": "#/$defs/Error"
},
"id": {
"$ref": "#/$defs/RequestId"
},
"jsonrpc": {
"type": "string",
"const": "2.0"
}
}
}Fields§
§error: RpcError§id: Option<RequestId>Implementations§
Trait Implementations§
Source§impl Clone for JsonrpcErrorResponse
impl Clone for JsonrpcErrorResponse
Source§fn clone(&self) -> JsonrpcErrorResponse
fn clone(&self) -> JsonrpcErrorResponse
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 JsonrpcErrorResponse
impl Debug for JsonrpcErrorResponse
Source§impl<'de> Deserialize<'de> for JsonrpcErrorResponse
impl<'de> Deserialize<'de> for JsonrpcErrorResponse
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 Display for JsonrpcErrorResponse
Formats the ServerJsonrpcResponse as a JSON string.
impl Display for JsonrpcErrorResponse
Formats the ServerJsonrpcResponse as a JSON string.
Source§impl From<JsonrpcErrorResponse> for JsonrpcMessage
impl From<JsonrpcErrorResponse> for JsonrpcMessage
Source§fn from(value: JsonrpcErrorResponse) -> Self
fn from(value: JsonrpcErrorResponse) -> Self
Converts to this type from the input type.
Source§impl From<JsonrpcErrorResponse> for JsonrpcResponse
impl From<JsonrpcErrorResponse> for JsonrpcResponse
Source§fn from(value: JsonrpcErrorResponse) -> Self
fn from(value: JsonrpcErrorResponse) -> Self
Converts to this type from the input type.
Source§impl FromStr for JsonrpcErrorResponse
impl FromStr for JsonrpcErrorResponse
Auto Trait Implementations§
impl Freeze for JsonrpcErrorResponse
impl RefUnwindSafe for JsonrpcErrorResponse
impl Send for JsonrpcErrorResponse
impl Sync for JsonrpcErrorResponse
impl Unpin for JsonrpcErrorResponse
impl UnwindSafe for JsonrpcErrorResponse
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