pub enum ServerFnErrorErr<E = NoCustomError> {
WrappedServerError(E),
Registration(String),
Request(String),
ServerError(String),
Deserialization(String),
Serialization(String),
Args(String),
MissingArg(String),
Response(String),
}
Expand description
Type for errors that can occur when using server functions.
Unlike ServerFnError
, this implements std::error::Error
. This means
it can be used in situations in which the Error
trait is required, but it’s
not possible to create a blanket implementation that converts other errors into
this type.
ServerFnError
and ServerFnErrorErr
mutually implement From
, so
it is easy to convert between the two types.
Variants§
WrappedServerError(E)
A user-defined custom error type, which defaults to NoCustomError
.
Registration(String)
Error while trying to register the server function (only occurs in case of poisoned RwLock).
Request(String)
Occurs on the client if there is a network error while trying to run function on server.
ServerError(String)
Occurs when there is an error while actually running the function on the server.
Deserialization(String)
Occurs on the client if there is an error deserializing the server’s response.
Serialization(String)
Occurs on the client if there is an error serializing the server function arguments.
Args(String)
Occurs on the server if there is an error deserializing one of the arguments that’s been sent.
MissingArg(String)
Occurs on the server if there’s a missing argument.
Response(String)
Occurs on the server if there is an error creating an HTTP response.
Trait Implementations§
Source§impl<E> Clone for ServerFnErrorErr<E>where
E: Clone,
impl<E> Clone for ServerFnErrorErr<E>where
E: Clone,
Source§fn clone(&self) -> ServerFnErrorErr<E>
fn clone(&self) -> ServerFnErrorErr<E>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more