pub enum Error {
Http(Error),
Deserialize(DeserializeBodyError),
Validation(ValidationError),
CachePermissions(ChannelError),
}Expand description
An error occurred when trying to update the cache
Variants§
Http(Error)
An error was returned by Twilight’s HTTP client while making the request
Deserialize(DeserializeBodyError)
An error was returned by Twilight’s HTTP client while deserializing the response
Validation(ValidationError)
An error was returned by Twilight while validating a request
CachePermissions(ChannelError)
An error was returned by Twilight while trying to get the permissions from the cache
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()
Source§impl From<ChannelError> for Error
impl From<ChannelError> for Error
Source§fn from(source: ChannelError) -> Self
fn from(source: ChannelError) -> Self
Converts to this type from the input type.
Source§impl From<DeserializeBodyError> for Error
impl From<DeserializeBodyError> for Error
Source§fn from(source: DeserializeBodyError) -> Self
fn from(source: DeserializeBodyError) -> Self
Converts to this type from the input type.
Source§impl From<ValidationError> for Error
impl From<ValidationError> for Error
Source§fn from(source: ValidationError) -> Self
fn from(source: ValidationError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !Freeze for Error
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> 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