#[non_exhaustive]pub enum Error {
BadRequestError(BadRequestError),
ForbiddenError(ForbiddenError),
InternalError(InternalError),
NotFoundError(NotFoundError),
RateLimitError(RateLimitError),
UnauthorizedError(UnauthorizedError),
Unhandled(Box<dyn Error + Send + Sync + 'static>),
}
Expand description
All possible error types for this service.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
BadRequestError(BadRequestError)
An error thrown when the requestee has sent an invalid or malformed request.
ForbiddenError(ForbiddenError)
An error thrown when the requestee requests a resource they do not have access to.
InternalError(InternalError)
An error caused by internal server problems.
NotFoundError(NotFoundError)
An error thrown when the requestee requests a non existant resource.
RateLimitError(RateLimitError)
An error thrown when the requestee has hit a rate limit. You are sending too many requests too quickly.
An error thrown when the requestee is not authenticated.
Unhandled(Box<dyn Error + Send + Sync + 'static>)
An unhandled error occurred.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()
Source§impl<R> From<SdkError<GetDirectThreadError, R>> for Error
impl<R> From<SdkError<GetDirectThreadError, R>> for Error
Source§fn from(err: SdkError<GetDirectThreadError, R>) -> Self
fn from(err: SdkError<GetDirectThreadError, R>) -> Self
Converts to this type from the input type.
Source§impl<R> From<SdkError<GetThreadHistoryError, R>> for Error
impl<R> From<SdkError<GetThreadHistoryError, R>> for Error
Source§fn from(err: SdkError<GetThreadHistoryError, R>) -> Self
fn from(err: SdkError<GetThreadHistoryError, R>) -> Self
Converts to this type from the input type.
Source§impl<R> From<SdkError<GetThreadTopicError, R>> for Error
impl<R> From<SdkError<GetThreadTopicError, R>> for Error
Source§fn from(err: SdkError<GetThreadTopicError, R>) -> Self
fn from(err: SdkError<GetThreadTopicError, R>) -> Self
Converts to this type from the input type.
Source§impl<R> From<SdkError<SendChatMessageError, R>> for Error
impl<R> From<SdkError<SendChatMessageError, R>> for Error
Source§fn from(err: SdkError<SendChatMessageError, R>) -> Self
fn from(err: SdkError<SendChatMessageError, R>) -> Self
Converts to this type from the input type.
Source§impl<R> From<SdkError<SetThreadReadError, R>> for Error
impl<R> From<SdkError<SetThreadReadError, R>> for Error
Source§fn from(err: SdkError<SetThreadReadError, R>) -> Self
fn from(err: SdkError<SetThreadReadError, R>) -> 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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more