pub enum Code {
HttpError,
WebSocketError,
ClientInternalError,
ParseError,
InvalidRequest,
MethodNotFound,
InvalidParams,
InternalError,
ServerError,
Other(i32),
}
Expand description
See func RPC*Error()
definitions in:
https://github.com/tendermint/tendermint/blob/main/rpc/jsonrpc/types/types.go
Variants§
HttpError
Low-level HTTP error
WebSocketError
Low-level WebSocket error
ClientInternalError
An internal error occurred within the client.
This is an error unique to this client, and is not available in the Go client.
ParseError
Parse error i.e. invalid JSON (-32700)
InvalidRequest
Invalid request (-32600)
MethodNotFound
Method not found error (-32601)
InvalidParams
Invalid parameters (-32602)
InternalError
Internal RPC server error (-32603)
ServerError
Server error (-32000)
Other(i32)
Other error types
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Code
impl<'de> Deserialize<'de> for Code
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl Ord for Code
impl Ord for Code
Source§impl PartialOrd for Code
impl PartialOrd for Code
Source§impl Error for Code
impl Error for Code
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
impl Copy for Code
impl Eq for Code
impl StructuralPartialEq for Code
Auto Trait Implementations§
impl Freeze for Code
impl RefUnwindSafe for Code
impl Send for Code
impl Sync for Code
impl Unpin for Code
impl UnwindSafe for Code
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.