pub enum Error {
Show 30 variants InvalidUrl(String), RpcError(Error), ResponseHandler(String), Disconnect, NotificationMethod, WebSocketMessageType, MissingNotificationHandler, WebSocketError(WebSocketError), Timeout, ReceiverCtl, NoDataInSuccessResponse, NoDataInNotificationMessage, NoDataInErrorResponse, ErrorDeserializingServerMessageData(Error), ErrorDeserializingResponseData, StatusCode(u32), RpcCall(ServerError), BorshSerialize, BorshDeserialize(String), SerdeSerialize(String), SerdeDeserialize(String), BorshResponseDeserialize(String), ChannelRecvError, ChannelSendError, Utf8Error(Utf8Error), SerdeJSON(Error), Task(TaskError), ServerError(ServerError), SerdeJsonServerError(SerdeJsonServerError), RegexError(Error),
}

Variants§

§

InvalidUrl(String)

§

RpcError(Error)

§

ResponseHandler(String)

§

Disconnect

§

NotificationMethod

§

WebSocketMessageType

§

MissingNotificationHandler

§

WebSocketError(WebSocketError)

Underlying WebSocket error

§

Timeout

RPC call timeout

§

ReceiverCtl

Unable to send shutdown message to receiver

§

NoDataInSuccessResponse

RPC call succeeded but no data was received in success response

§

NoDataInNotificationMessage

§

NoDataInErrorResponse

RPC call failed but no data was received in error response

§

ErrorDeserializingServerMessageData(Error)

Unable to deserialize response data

§

ErrorDeserializingResponseData

Unable to deserialize response data

§

StatusCode(u32)

Response produced an unknown status code

§

RpcCall(ServerError)

RPC call executed successfully but produced an error response

§

BorshSerialize

Unable to serialize borsh data

§

BorshDeserialize(String)

Unable to deserialize borsh data

§

SerdeSerialize(String)

Unable to serialize serde data

§

SerdeDeserialize(String)

Unable to deserialize serde data

§

BorshResponseDeserialize(String)

RPC call succeeded, but error occurred deserializing borsh response

§

ChannelRecvError

§

ChannelSendError

§

Utf8Error(Utf8Error)

§

SerdeJSON(Error)

§

Task(TaskError)

§

ServerError(ServerError)

§

SerdeJsonServerError(SerdeJsonServerError)

§

RegexError(Error)

Trait Implementations§

source§

impl Debug for Error

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for Error

source§

fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Error for Error

source§

fn source(&self) -> Option<&(dyn Error + 'static)>

The lower-level source of this error, if any. Read more
1.0.0 · source§

fn description(&self) -> &str

👎Deprecated since 1.42.0: use the Display impl or to_string()
1.0.0 · source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
source§

fn provide<'a>(&'a self, demand: &mut Demand<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type based access to context intended for error reports. Read more
source§

impl Error for Error

source§

fn custom<T: Display>(msg: T) -> Error

Raised when there is general error when deserializing a type. Read more
source§

fn invalid_type(unexp: Unexpected<'_>, exp: &dyn Expected) -> Self

Raised when a Deserialize receives a type different from what it was expecting. Read more
source§

fn invalid_value(unexp: Unexpected<'_>, exp: &dyn Expected) -> Self

Raised when a Deserialize receives a value of the right type but that is wrong for some other reason. Read more
source§

fn invalid_length(len: usize, exp: &dyn Expected) -> Self

Raised when deserializing a sequence or map and the input data contains too many or too few elements. Read more
source§

fn unknown_variant(variant: &str, expected: &'static [&'static str]) -> Self

Raised when a Deserialize enum type received a variant with an unrecognized name.
source§

fn unknown_field(field: &str, expected: &'static [&'static str]) -> Self

Raised when a Deserialize struct type received a field with an unrecognized name.
source§

fn missing_field(field: &'static str) -> Self

Raised when a Deserialize struct type expected to receive a required field with a particular name but that field was not present in the input.
source§

fn duplicate_field(field: &'static str) -> Self

Raised when a Deserialize struct type received more than one of the same field.
source§

impl Error for Error

source§

fn custom<T: Display>(msg: T) -> Error

Used when a Serialize implementation encounters any error while serializing a type. Read more
source§

impl From<Error> for Error

source§

fn from(source: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

source§

fn from(source: WebSocketError) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

source§

fn from(source: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

source§

fn from(source: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for JsValue

Transform Error into JsValue containing the error message

source§

fn from(err: Error) -> JsValue

Converts to this type from the input type.
source§

impl From<RecvError> for Error

source§

fn from(_: RecvError) -> Self

Converts to this type from the input type.
source§

impl<T> From<SendError<T>> for Error

source§

fn from(_: SendError<T>) -> Self

Converts to this type from the input type.
source§

impl From<SerdeJsonServerError> for Error

source§

fn from(err: SerdeJsonServerError) -> Self

Converts to this type from the input type.
source§

impl From<ServerError> for Error

source§

fn from(err: ServerError) -> Self

Converts to this type from the input type.
source§

impl From<TaskError> for Error

source§

fn from(source: TaskError) -> Self

Converts to this type from the input type.
source§

impl<T> From<TrySendError<T>> for Error

source§

fn from(_: TrySendError<T>) -> Self

Converts to this type from the input type.
source§

impl From<Utf8Error> for Error

source§

fn from(source: Utf8Error) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

§

impl !RefUnwindSafe for Error

§

impl Send for Error

§

impl Sync for Error

§

impl Unpin for Error

§

impl !UnwindSafe for Error

Blanket Implementations§

source§

impl<T> Any for Twhere
T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Any for Twhere
T: Any,

§

fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>

§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>

§

fn type_name(&self) -> &'static str

§

impl<T> AnySync for Twhere
T: Any + Send + Sync,

§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Send + Sync + 'static>

source§

impl<T> Borrow<T> for Twhere
T: ?Sized,

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere
T: ?Sized,

const: unstable · source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> Downcast for Twhere
T: Any,

source§

fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>

Convert Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.
source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>

Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
source§

fn as_any(&self) -> &(dyn Any + 'static)

Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
source§

impl<T> DowncastSync for Twhere
T: Any + Send + Sync,

source§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Send + Sync + 'static>

Convert Arc<Trait> (where Trait: Downcast) to Arc<Any>. Arc<Any> can then be further downcast into Arc<ConcreteType> where ConcreteType implements Trait.
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere
U: From<T>,

const: unstable · source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<E> Provider for Ewhere
E: Error + ?Sized,

source§

fn provide<'a>(&'a self, demand: &mut Demand<'a>)

🔬This is a nightly-only experimental API. (provide_any)
Data providers should implement this method to provide all values they are able to provide by using demand. Read more
source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T> ToString for Twhere
T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for Twhere
U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere
U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
const: unstable · source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for Twhere
V: MultiLane<T>,

§

fn vzip(self) -> V