pub enum JmapMethodError {
Show 18 variants
ServerFail {
description: Option<String>,
},
ServerPartialFail,
ServerUnavailable {
description: Option<String>,
},
UnknownCapability {
description: Option<String>,
},
NotJson {
description: Option<String>,
},
NotRequest {
description: Option<String>,
},
Limit {
description: Option<String>,
limit: String,
},
InvalidArguments {
description: Option<String>,
},
Forbidden {
description: Option<String>,
},
RequestTooLarge,
NotFound,
InvalidPatch {
description: Option<String>,
},
WillDestroy {
description: Option<String>,
},
InvalidProperties {
description: Option<String>,
properties: Vec<String>,
},
Singleton,
UnknownMethod {
description: Option<String>,
},
CannotCalculateChanges {
description: Option<String>,
},
Unknown,
}Expand description
A JMAP method-level error (RFC 8620 §3.6.1).
NOTE: variants keep the struct shape even with a single field, the internally-tagged serde representation of the wire object requires it.
Variants§
ServerFail
An unexpected or unknown error occurred during the method call.
ServerPartialFail
Some, but not all, expected changes were applied.
The server is currently unable to run the method.
UnknownCapability
The method requires a capability the request did not declare.
NotJson
The request body was not valid JSON.
NotRequest
The request parsed as JSON but is not a valid Request object.
Limit
A server-defined limit was exceeded.
Fields
InvalidArguments
One of the method arguments is invalid.
Forbidden
Access denied for this method call (RFC 8620 §3.6.2), e.g. requesting
the url or keys properties in PushSubscription/get (§7.2.1).
RequestTooLarge
The total request size exceeds the server limit.
NotFound
The referenced object does not exist.
InvalidPatch
A Foo/set update patch is invalid.
WillDestroy
The object will be destroyed by this request, so it cannot be updated.
InvalidProperties
One or more object properties are invalid.
Fields
Singleton
The type is a singleton, objects cannot be created or destroyed.
UnknownMethod
The method name is not known by the server.
CannotCalculateChanges
Server can no longer compute changes from sinceState (RFC 8620 §5.2):
callers MUST fall back to Foo/get and resume from the returned state.
Unknown
Any error type this library does not know about.
Trait Implementations§
Source§impl Clone for JmapMethodError
impl Clone for JmapMethodError
Source§fn clone(&self) -> JmapMethodError
fn clone(&self) -> JmapMethodError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for JmapMethodError
impl Debug for JmapMethodError
Source§impl<'de> Deserialize<'de> for JmapMethodError
impl<'de> Deserialize<'de> for JmapMethodError
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>,
Source§impl Display for JmapMethodError
impl Display for JmapMethodError
Source§impl Error for JmapMethodError
impl Error for JmapMethodError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()