#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CancelGameLinkError {
pub kind: CancelGameLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CancelGameLinkErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for CancelGameLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CancelGameLinkErrorKind::InternalError(_inner) => _inner.fmt(f),
CancelGameLinkErrorKind::RateLimitError(_inner) => _inner.fmt(f),
CancelGameLinkErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
CancelGameLinkErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
CancelGameLinkErrorKind::NotFoundError(_inner) => _inner.fmt(f),
CancelGameLinkErrorKind::BadRequestError(_inner) => _inner.fmt(f),
CancelGameLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CancelGameLinkError {
fn code(&self) -> Option<&str> {
CancelGameLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
CancelGameLinkErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
CancelGameLinkErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl CancelGameLinkError {
pub fn new(kind: CancelGameLinkErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: CancelGameLinkErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CancelGameLinkErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, CancelGameLinkErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, CancelGameLinkErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, CancelGameLinkErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, CancelGameLinkErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, CancelGameLinkErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, CancelGameLinkErrorKind::BadRequestError(_))
}
}
impl std::error::Error for CancelGameLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CancelGameLinkErrorKind::InternalError(_inner) => Some(_inner),
CancelGameLinkErrorKind::RateLimitError(_inner) => Some(_inner),
CancelGameLinkErrorKind::ForbiddenError(_inner) => Some(_inner),
CancelGameLinkErrorKind::UnauthorizedError(_inner) => Some(_inner),
CancelGameLinkErrorKind::NotFoundError(_inner) => Some(_inner),
CancelGameLinkErrorKind::BadRequestError(_inner) => Some(_inner),
CancelGameLinkErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CompleteGameLinkError {
pub kind: CompleteGameLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CompleteGameLinkErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for CompleteGameLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CompleteGameLinkErrorKind::InternalError(_inner) => _inner.fmt(f),
CompleteGameLinkErrorKind::RateLimitError(_inner) => _inner.fmt(f),
CompleteGameLinkErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
CompleteGameLinkErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
CompleteGameLinkErrorKind::NotFoundError(_inner) => _inner.fmt(f),
CompleteGameLinkErrorKind::BadRequestError(_inner) => _inner.fmt(f),
CompleteGameLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CompleteGameLinkError {
fn code(&self) -> Option<&str> {
CompleteGameLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
CompleteGameLinkErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
CompleteGameLinkErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl CompleteGameLinkError {
pub fn new(kind: CompleteGameLinkErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: CompleteGameLinkErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CompleteGameLinkErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, CompleteGameLinkErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, CompleteGameLinkErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, CompleteGameLinkErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, CompleteGameLinkErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, CompleteGameLinkErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, CompleteGameLinkErrorKind::BadRequestError(_))
}
}
impl std::error::Error for CompleteGameLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CompleteGameLinkErrorKind::InternalError(_inner) => Some(_inner),
CompleteGameLinkErrorKind::RateLimitError(_inner) => Some(_inner),
CompleteGameLinkErrorKind::ForbiddenError(_inner) => Some(_inner),
CompleteGameLinkErrorKind::UnauthorizedError(_inner) => Some(_inner),
CompleteGameLinkErrorKind::NotFoundError(_inner) => Some(_inner),
CompleteGameLinkErrorKind::BadRequestError(_inner) => Some(_inner),
CompleteGameLinkErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct CompleteIdentityAvatarUploadError {
pub kind: CompleteIdentityAvatarUploadErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum CompleteIdentityAvatarUploadErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for CompleteIdentityAvatarUploadError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
CompleteIdentityAvatarUploadErrorKind::InternalError(_inner) => _inner.fmt(f),
CompleteIdentityAvatarUploadErrorKind::RateLimitError(_inner) => _inner.fmt(f),
CompleteIdentityAvatarUploadErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
CompleteIdentityAvatarUploadErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
CompleteIdentityAvatarUploadErrorKind::NotFoundError(_inner) => _inner.fmt(f),
CompleteIdentityAvatarUploadErrorKind::BadRequestError(_inner) => _inner.fmt(f),
CompleteIdentityAvatarUploadErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for CompleteIdentityAvatarUploadError {
fn code(&self) -> Option<&str> {
CompleteIdentityAvatarUploadError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
CompleteIdentityAvatarUploadErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
CompleteIdentityAvatarUploadErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl CompleteIdentityAvatarUploadError {
pub fn new(kind: CompleteIdentityAvatarUploadErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: CompleteIdentityAvatarUploadErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: CompleteIdentityAvatarUploadErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(
&self.kind,
CompleteIdentityAvatarUploadErrorKind::InternalError(_)
)
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
CompleteIdentityAvatarUploadErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
CompleteIdentityAvatarUploadErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
CompleteIdentityAvatarUploadErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(
&self.kind,
CompleteIdentityAvatarUploadErrorKind::NotFoundError(_)
)
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
CompleteIdentityAvatarUploadErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for CompleteIdentityAvatarUploadError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
CompleteIdentityAvatarUploadErrorKind::InternalError(_inner) => Some(_inner),
CompleteIdentityAvatarUploadErrorKind::RateLimitError(_inner) => Some(_inner),
CompleteIdentityAvatarUploadErrorKind::ForbiddenError(_inner) => Some(_inner),
CompleteIdentityAvatarUploadErrorKind::UnauthorizedError(_inner) => Some(_inner),
CompleteIdentityAvatarUploadErrorKind::NotFoundError(_inner) => Some(_inner),
CompleteIdentityAvatarUploadErrorKind::BadRequestError(_inner) => Some(_inner),
CompleteIdentityAvatarUploadErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct FollowIdentityError {
pub kind: FollowIdentityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum FollowIdentityErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for FollowIdentityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
FollowIdentityErrorKind::InternalError(_inner) => _inner.fmt(f),
FollowIdentityErrorKind::RateLimitError(_inner) => _inner.fmt(f),
FollowIdentityErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
FollowIdentityErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
FollowIdentityErrorKind::NotFoundError(_inner) => _inner.fmt(f),
FollowIdentityErrorKind::BadRequestError(_inner) => _inner.fmt(f),
FollowIdentityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for FollowIdentityError {
fn code(&self) -> Option<&str> {
FollowIdentityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
FollowIdentityErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
FollowIdentityErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl FollowIdentityError {
pub fn new(kind: FollowIdentityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: FollowIdentityErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: FollowIdentityErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, FollowIdentityErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, FollowIdentityErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, FollowIdentityErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, FollowIdentityErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, FollowIdentityErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, FollowIdentityErrorKind::BadRequestError(_))
}
}
impl std::error::Error for FollowIdentityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
FollowIdentityErrorKind::InternalError(_inner) => Some(_inner),
FollowIdentityErrorKind::RateLimitError(_inner) => Some(_inner),
FollowIdentityErrorKind::ForbiddenError(_inner) => Some(_inner),
FollowIdentityErrorKind::UnauthorizedError(_inner) => Some(_inner),
FollowIdentityErrorKind::NotFoundError(_inner) => Some(_inner),
FollowIdentityErrorKind::BadRequestError(_inner) => Some(_inner),
FollowIdentityErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetGameLinkError {
pub kind: GetGameLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetGameLinkErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for GetGameLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetGameLinkErrorKind::InternalError(_inner) => _inner.fmt(f),
GetGameLinkErrorKind::RateLimitError(_inner) => _inner.fmt(f),
GetGameLinkErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
GetGameLinkErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
GetGameLinkErrorKind::NotFoundError(_inner) => _inner.fmt(f),
GetGameLinkErrorKind::BadRequestError(_inner) => _inner.fmt(f),
GetGameLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetGameLinkError {
fn code(&self) -> Option<&str> {
GetGameLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
GetGameLinkErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
GetGameLinkErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl GetGameLinkError {
pub fn new(kind: GetGameLinkErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetGameLinkErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetGameLinkErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, GetGameLinkErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, GetGameLinkErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, GetGameLinkErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, GetGameLinkErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, GetGameLinkErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, GetGameLinkErrorKind::BadRequestError(_))
}
}
impl std::error::Error for GetGameLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetGameLinkErrorKind::InternalError(_inner) => Some(_inner),
GetGameLinkErrorKind::RateLimitError(_inner) => Some(_inner),
GetGameLinkErrorKind::ForbiddenError(_inner) => Some(_inner),
GetGameLinkErrorKind::UnauthorizedError(_inner) => Some(_inner),
GetGameLinkErrorKind::NotFoundError(_inner) => Some(_inner),
GetGameLinkErrorKind::BadRequestError(_inner) => Some(_inner),
GetGameLinkErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetIdentityHandlesError {
pub kind: GetIdentityHandlesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetIdentityHandlesErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for GetIdentityHandlesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetIdentityHandlesErrorKind::InternalError(_inner) => _inner.fmt(f),
GetIdentityHandlesErrorKind::RateLimitError(_inner) => _inner.fmt(f),
GetIdentityHandlesErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
GetIdentityHandlesErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
GetIdentityHandlesErrorKind::NotFoundError(_inner) => _inner.fmt(f),
GetIdentityHandlesErrorKind::BadRequestError(_inner) => _inner.fmt(f),
GetIdentityHandlesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetIdentityHandlesError {
fn code(&self) -> Option<&str> {
GetIdentityHandlesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
GetIdentityHandlesErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
GetIdentityHandlesErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl GetIdentityHandlesError {
pub fn new(kind: GetIdentityHandlesErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetIdentityHandlesErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetIdentityHandlesErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, GetIdentityHandlesErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, GetIdentityHandlesErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, GetIdentityHandlesErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
GetIdentityHandlesErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, GetIdentityHandlesErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, GetIdentityHandlesErrorKind::BadRequestError(_))
}
}
impl std::error::Error for GetIdentityHandlesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetIdentityHandlesErrorKind::InternalError(_inner) => Some(_inner),
GetIdentityHandlesErrorKind::RateLimitError(_inner) => Some(_inner),
GetIdentityHandlesErrorKind::ForbiddenError(_inner) => Some(_inner),
GetIdentityHandlesErrorKind::UnauthorizedError(_inner) => Some(_inner),
GetIdentityHandlesErrorKind::NotFoundError(_inner) => Some(_inner),
GetIdentityHandlesErrorKind::BadRequestError(_inner) => Some(_inner),
GetIdentityHandlesErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetIdentityProfileError {
pub kind: GetIdentityProfileErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetIdentityProfileErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for GetIdentityProfileError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetIdentityProfileErrorKind::InternalError(_inner) => _inner.fmt(f),
GetIdentityProfileErrorKind::RateLimitError(_inner) => _inner.fmt(f),
GetIdentityProfileErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
GetIdentityProfileErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
GetIdentityProfileErrorKind::NotFoundError(_inner) => _inner.fmt(f),
GetIdentityProfileErrorKind::BadRequestError(_inner) => _inner.fmt(f),
GetIdentityProfileErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetIdentityProfileError {
fn code(&self) -> Option<&str> {
GetIdentityProfileError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
GetIdentityProfileErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
GetIdentityProfileErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl GetIdentityProfileError {
pub fn new(kind: GetIdentityProfileErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetIdentityProfileErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetIdentityProfileErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, GetIdentityProfileErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, GetIdentityProfileErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, GetIdentityProfileErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
GetIdentityProfileErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, GetIdentityProfileErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, GetIdentityProfileErrorKind::BadRequestError(_))
}
}
impl std::error::Error for GetIdentityProfileError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetIdentityProfileErrorKind::InternalError(_inner) => Some(_inner),
GetIdentityProfileErrorKind::RateLimitError(_inner) => Some(_inner),
GetIdentityProfileErrorKind::ForbiddenError(_inner) => Some(_inner),
GetIdentityProfileErrorKind::UnauthorizedError(_inner) => Some(_inner),
GetIdentityProfileErrorKind::NotFoundError(_inner) => Some(_inner),
GetIdentityProfileErrorKind::BadRequestError(_inner) => Some(_inner),
GetIdentityProfileErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetIdentitySelfProfileError {
pub kind: GetIdentitySelfProfileErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetIdentitySelfProfileErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for GetIdentitySelfProfileError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetIdentitySelfProfileErrorKind::InternalError(_inner) => _inner.fmt(f),
GetIdentitySelfProfileErrorKind::RateLimitError(_inner) => _inner.fmt(f),
GetIdentitySelfProfileErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
GetIdentitySelfProfileErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
GetIdentitySelfProfileErrorKind::NotFoundError(_inner) => _inner.fmt(f),
GetIdentitySelfProfileErrorKind::BadRequestError(_inner) => _inner.fmt(f),
GetIdentitySelfProfileErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetIdentitySelfProfileError {
fn code(&self) -> Option<&str> {
GetIdentitySelfProfileError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
GetIdentitySelfProfileErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
GetIdentitySelfProfileErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl GetIdentitySelfProfileError {
pub fn new(kind: GetIdentitySelfProfileErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetIdentitySelfProfileErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetIdentitySelfProfileErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySelfProfileErrorKind::InternalError(_)
)
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySelfProfileErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySelfProfileErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySelfProfileErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySelfProfileErrorKind::NotFoundError(_)
)
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySelfProfileErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for GetIdentitySelfProfileError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetIdentitySelfProfileErrorKind::InternalError(_inner) => Some(_inner),
GetIdentitySelfProfileErrorKind::RateLimitError(_inner) => Some(_inner),
GetIdentitySelfProfileErrorKind::ForbiddenError(_inner) => Some(_inner),
GetIdentitySelfProfileErrorKind::UnauthorizedError(_inner) => Some(_inner),
GetIdentitySelfProfileErrorKind::NotFoundError(_inner) => Some(_inner),
GetIdentitySelfProfileErrorKind::BadRequestError(_inner) => Some(_inner),
GetIdentitySelfProfileErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct GetIdentitySummariesError {
pub kind: GetIdentitySummariesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum GetIdentitySummariesErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for GetIdentitySummariesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
GetIdentitySummariesErrorKind::InternalError(_inner) => _inner.fmt(f),
GetIdentitySummariesErrorKind::RateLimitError(_inner) => _inner.fmt(f),
GetIdentitySummariesErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
GetIdentitySummariesErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
GetIdentitySummariesErrorKind::NotFoundError(_inner) => _inner.fmt(f),
GetIdentitySummariesErrorKind::BadRequestError(_inner) => _inner.fmt(f),
GetIdentitySummariesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for GetIdentitySummariesError {
fn code(&self) -> Option<&str> {
GetIdentitySummariesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
GetIdentitySummariesErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
GetIdentitySummariesErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl GetIdentitySummariesError {
pub fn new(kind: GetIdentitySummariesErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: GetIdentitySummariesErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: GetIdentitySummariesErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, GetIdentitySummariesErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, GetIdentitySummariesErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, GetIdentitySummariesErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySummariesErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, GetIdentitySummariesErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
GetIdentitySummariesErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for GetIdentitySummariesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
GetIdentitySummariesErrorKind::InternalError(_inner) => Some(_inner),
GetIdentitySummariesErrorKind::RateLimitError(_inner) => Some(_inner),
GetIdentitySummariesErrorKind::ForbiddenError(_inner) => Some(_inner),
GetIdentitySummariesErrorKind::UnauthorizedError(_inner) => Some(_inner),
GetIdentitySummariesErrorKind::NotFoundError(_inner) => Some(_inner),
GetIdentitySummariesErrorKind::BadRequestError(_inner) => Some(_inner),
GetIdentitySummariesErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListActivitiesError {
pub kind: ListActivitiesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListActivitiesErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ListActivitiesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListActivitiesErrorKind::InternalError(_inner) => _inner.fmt(f),
ListActivitiesErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ListActivitiesErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ListActivitiesErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ListActivitiesErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ListActivitiesErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ListActivitiesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListActivitiesError {
fn code(&self) -> Option<&str> {
ListActivitiesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ListActivitiesErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
ListActivitiesErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl ListActivitiesError {
pub fn new(kind: ListActivitiesErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListActivitiesErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListActivitiesErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, ListActivitiesErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, ListActivitiesErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, ListActivitiesErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, ListActivitiesErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, ListActivitiesErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, ListActivitiesErrorKind::BadRequestError(_))
}
}
impl std::error::Error for ListActivitiesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListActivitiesErrorKind::InternalError(_inner) => Some(_inner),
ListActivitiesErrorKind::RateLimitError(_inner) => Some(_inner),
ListActivitiesErrorKind::ForbiddenError(_inner) => Some(_inner),
ListActivitiesErrorKind::UnauthorizedError(_inner) => Some(_inner),
ListActivitiesErrorKind::NotFoundError(_inner) => Some(_inner),
ListActivitiesErrorKind::BadRequestError(_inner) => Some(_inner),
ListActivitiesErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListFollowersError {
pub kind: ListFollowersErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListFollowersErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ListFollowersError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListFollowersErrorKind::InternalError(_inner) => _inner.fmt(f),
ListFollowersErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ListFollowersErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ListFollowersErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ListFollowersErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ListFollowersErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ListFollowersErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListFollowersError {
fn code(&self) -> Option<&str> {
ListFollowersError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ListFollowersErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
ListFollowersErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl ListFollowersError {
pub fn new(kind: ListFollowersErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListFollowersErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListFollowersErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, ListFollowersErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, ListFollowersErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, ListFollowersErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, ListFollowersErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, ListFollowersErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, ListFollowersErrorKind::BadRequestError(_))
}
}
impl std::error::Error for ListFollowersError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListFollowersErrorKind::InternalError(_inner) => Some(_inner),
ListFollowersErrorKind::RateLimitError(_inner) => Some(_inner),
ListFollowersErrorKind::ForbiddenError(_inner) => Some(_inner),
ListFollowersErrorKind::UnauthorizedError(_inner) => Some(_inner),
ListFollowersErrorKind::NotFoundError(_inner) => Some(_inner),
ListFollowersErrorKind::BadRequestError(_inner) => Some(_inner),
ListFollowersErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListFollowingError {
pub kind: ListFollowingErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListFollowingErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ListFollowingError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListFollowingErrorKind::InternalError(_inner) => _inner.fmt(f),
ListFollowingErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ListFollowingErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ListFollowingErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ListFollowingErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ListFollowingErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ListFollowingErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListFollowingError {
fn code(&self) -> Option<&str> {
ListFollowingError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ListFollowingErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
ListFollowingErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl ListFollowingError {
pub fn new(kind: ListFollowingErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListFollowingErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListFollowingErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, ListFollowingErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, ListFollowingErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, ListFollowingErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, ListFollowingErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, ListFollowingErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, ListFollowingErrorKind::BadRequestError(_))
}
}
impl std::error::Error for ListFollowingError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListFollowingErrorKind::InternalError(_inner) => Some(_inner),
ListFollowingErrorKind::RateLimitError(_inner) => Some(_inner),
ListFollowingErrorKind::ForbiddenError(_inner) => Some(_inner),
ListFollowingErrorKind::UnauthorizedError(_inner) => Some(_inner),
ListFollowingErrorKind::NotFoundError(_inner) => Some(_inner),
ListFollowingErrorKind::BadRequestError(_inner) => Some(_inner),
ListFollowingErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListFriendsError {
pub kind: ListFriendsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListFriendsErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ListFriendsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListFriendsErrorKind::InternalError(_inner) => _inner.fmt(f),
ListFriendsErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ListFriendsErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ListFriendsErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ListFriendsErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ListFriendsErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ListFriendsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListFriendsError {
fn code(&self) -> Option<&str> {
ListFriendsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ListFriendsErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
ListFriendsErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl ListFriendsError {
pub fn new(kind: ListFriendsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListFriendsErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListFriendsErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, ListFriendsErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, ListFriendsErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, ListFriendsErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, ListFriendsErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, ListFriendsErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, ListFriendsErrorKind::BadRequestError(_))
}
}
impl std::error::Error for ListFriendsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListFriendsErrorKind::InternalError(_inner) => Some(_inner),
ListFriendsErrorKind::RateLimitError(_inner) => Some(_inner),
ListFriendsErrorKind::ForbiddenError(_inner) => Some(_inner),
ListFriendsErrorKind::UnauthorizedError(_inner) => Some(_inner),
ListFriendsErrorKind::NotFoundError(_inner) => Some(_inner),
ListFriendsErrorKind::BadRequestError(_inner) => Some(_inner),
ListFriendsErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ListMutualFriendsError {
pub kind: ListMutualFriendsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ListMutualFriendsErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ListMutualFriendsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ListMutualFriendsErrorKind::InternalError(_inner) => _inner.fmt(f),
ListMutualFriendsErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ListMutualFriendsErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ListMutualFriendsErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ListMutualFriendsErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ListMutualFriendsErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ListMutualFriendsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ListMutualFriendsError {
fn code(&self) -> Option<&str> {
ListMutualFriendsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ListMutualFriendsErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
ListMutualFriendsErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl ListMutualFriendsError {
pub fn new(kind: ListMutualFriendsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ListMutualFriendsErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ListMutualFriendsErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, ListMutualFriendsErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, ListMutualFriendsErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, ListMutualFriendsErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, ListMutualFriendsErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, ListMutualFriendsErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, ListMutualFriendsErrorKind::BadRequestError(_))
}
}
impl std::error::Error for ListMutualFriendsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ListMutualFriendsErrorKind::InternalError(_inner) => Some(_inner),
ListMutualFriendsErrorKind::RateLimitError(_inner) => Some(_inner),
ListMutualFriendsErrorKind::ForbiddenError(_inner) => Some(_inner),
ListMutualFriendsErrorKind::UnauthorizedError(_inner) => Some(_inner),
ListMutualFriendsErrorKind::NotFoundError(_inner) => Some(_inner),
ListMutualFriendsErrorKind::BadRequestError(_inner) => Some(_inner),
ListMutualFriendsErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PrepareGameLinkError {
pub kind: PrepareGameLinkErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PrepareGameLinkErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for PrepareGameLinkError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PrepareGameLinkErrorKind::InternalError(_inner) => _inner.fmt(f),
PrepareGameLinkErrorKind::RateLimitError(_inner) => _inner.fmt(f),
PrepareGameLinkErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
PrepareGameLinkErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
PrepareGameLinkErrorKind::NotFoundError(_inner) => _inner.fmt(f),
PrepareGameLinkErrorKind::BadRequestError(_inner) => _inner.fmt(f),
PrepareGameLinkErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PrepareGameLinkError {
fn code(&self) -> Option<&str> {
PrepareGameLinkError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
PrepareGameLinkErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
PrepareGameLinkErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl PrepareGameLinkError {
pub fn new(kind: PrepareGameLinkErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: PrepareGameLinkErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PrepareGameLinkErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, PrepareGameLinkErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, PrepareGameLinkErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, PrepareGameLinkErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, PrepareGameLinkErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, PrepareGameLinkErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, PrepareGameLinkErrorKind::BadRequestError(_))
}
}
impl std::error::Error for PrepareGameLinkError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PrepareGameLinkErrorKind::InternalError(_inner) => Some(_inner),
PrepareGameLinkErrorKind::RateLimitError(_inner) => Some(_inner),
PrepareGameLinkErrorKind::ForbiddenError(_inner) => Some(_inner),
PrepareGameLinkErrorKind::UnauthorizedError(_inner) => Some(_inner),
PrepareGameLinkErrorKind::NotFoundError(_inner) => Some(_inner),
PrepareGameLinkErrorKind::BadRequestError(_inner) => Some(_inner),
PrepareGameLinkErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct PrepareIdentityAvatarUploadError {
pub kind: PrepareIdentityAvatarUploadErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum PrepareIdentityAvatarUploadErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for PrepareIdentityAvatarUploadError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
PrepareIdentityAvatarUploadErrorKind::InternalError(_inner) => _inner.fmt(f),
PrepareIdentityAvatarUploadErrorKind::RateLimitError(_inner) => _inner.fmt(f),
PrepareIdentityAvatarUploadErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
PrepareIdentityAvatarUploadErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
PrepareIdentityAvatarUploadErrorKind::NotFoundError(_inner) => _inner.fmt(f),
PrepareIdentityAvatarUploadErrorKind::BadRequestError(_inner) => _inner.fmt(f),
PrepareIdentityAvatarUploadErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for PrepareIdentityAvatarUploadError {
fn code(&self) -> Option<&str> {
PrepareIdentityAvatarUploadError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
PrepareIdentityAvatarUploadErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
PrepareIdentityAvatarUploadErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl PrepareIdentityAvatarUploadError {
pub fn new(kind: PrepareIdentityAvatarUploadErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: PrepareIdentityAvatarUploadErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: PrepareIdentityAvatarUploadErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(
&self.kind,
PrepareIdentityAvatarUploadErrorKind::InternalError(_)
)
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
PrepareIdentityAvatarUploadErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
PrepareIdentityAvatarUploadErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
PrepareIdentityAvatarUploadErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(
&self.kind,
PrepareIdentityAvatarUploadErrorKind::NotFoundError(_)
)
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
PrepareIdentityAvatarUploadErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for PrepareIdentityAvatarUploadError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
PrepareIdentityAvatarUploadErrorKind::InternalError(_inner) => Some(_inner),
PrepareIdentityAvatarUploadErrorKind::RateLimitError(_inner) => Some(_inner),
PrepareIdentityAvatarUploadErrorKind::ForbiddenError(_inner) => Some(_inner),
PrepareIdentityAvatarUploadErrorKind::UnauthorizedError(_inner) => Some(_inner),
PrepareIdentityAvatarUploadErrorKind::NotFoundError(_inner) => Some(_inner),
PrepareIdentityAvatarUploadErrorKind::BadRequestError(_inner) => Some(_inner),
PrepareIdentityAvatarUploadErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct RemoveIdentityGameActivityError {
pub kind: RemoveIdentityGameActivityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum RemoveIdentityGameActivityErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for RemoveIdentityGameActivityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
RemoveIdentityGameActivityErrorKind::InternalError(_inner) => _inner.fmt(f),
RemoveIdentityGameActivityErrorKind::RateLimitError(_inner) => _inner.fmt(f),
RemoveIdentityGameActivityErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
RemoveIdentityGameActivityErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
RemoveIdentityGameActivityErrorKind::NotFoundError(_inner) => _inner.fmt(f),
RemoveIdentityGameActivityErrorKind::BadRequestError(_inner) => _inner.fmt(f),
RemoveIdentityGameActivityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for RemoveIdentityGameActivityError {
fn code(&self) -> Option<&str> {
RemoveIdentityGameActivityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
RemoveIdentityGameActivityErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
RemoveIdentityGameActivityErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl RemoveIdentityGameActivityError {
pub fn new(kind: RemoveIdentityGameActivityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: RemoveIdentityGameActivityErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: RemoveIdentityGameActivityErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(
&self.kind,
RemoveIdentityGameActivityErrorKind::InternalError(_)
)
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
RemoveIdentityGameActivityErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
RemoveIdentityGameActivityErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
RemoveIdentityGameActivityErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(
&self.kind,
RemoveIdentityGameActivityErrorKind::NotFoundError(_)
)
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
RemoveIdentityGameActivityErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for RemoveIdentityGameActivityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
RemoveIdentityGameActivityErrorKind::InternalError(_inner) => Some(_inner),
RemoveIdentityGameActivityErrorKind::RateLimitError(_inner) => Some(_inner),
RemoveIdentityGameActivityErrorKind::ForbiddenError(_inner) => Some(_inner),
RemoveIdentityGameActivityErrorKind::UnauthorizedError(_inner) => Some(_inner),
RemoveIdentityGameActivityErrorKind::NotFoundError(_inner) => Some(_inner),
RemoveIdentityGameActivityErrorKind::BadRequestError(_inner) => Some(_inner),
RemoveIdentityGameActivityErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ReportIdentityError {
pub kind: ReportIdentityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ReportIdentityErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ReportIdentityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ReportIdentityErrorKind::InternalError(_inner) => _inner.fmt(f),
ReportIdentityErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ReportIdentityErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ReportIdentityErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ReportIdentityErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ReportIdentityErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ReportIdentityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ReportIdentityError {
fn code(&self) -> Option<&str> {
ReportIdentityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ReportIdentityErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
ReportIdentityErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl ReportIdentityError {
pub fn new(kind: ReportIdentityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ReportIdentityErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ReportIdentityErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, ReportIdentityErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, ReportIdentityErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, ReportIdentityErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, ReportIdentityErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, ReportIdentityErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, ReportIdentityErrorKind::BadRequestError(_))
}
}
impl std::error::Error for ReportIdentityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ReportIdentityErrorKind::InternalError(_inner) => Some(_inner),
ReportIdentityErrorKind::RateLimitError(_inner) => Some(_inner),
ReportIdentityErrorKind::ForbiddenError(_inner) => Some(_inner),
ReportIdentityErrorKind::UnauthorizedError(_inner) => Some(_inner),
ReportIdentityErrorKind::NotFoundError(_inner) => Some(_inner),
ReportIdentityErrorKind::BadRequestError(_inner) => Some(_inner),
ReportIdentityErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SearchIdentitiesError {
pub kind: SearchIdentitiesErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SearchIdentitiesErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for SearchIdentitiesError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SearchIdentitiesErrorKind::InternalError(_inner) => _inner.fmt(f),
SearchIdentitiesErrorKind::RateLimitError(_inner) => _inner.fmt(f),
SearchIdentitiesErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
SearchIdentitiesErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
SearchIdentitiesErrorKind::NotFoundError(_inner) => _inner.fmt(f),
SearchIdentitiesErrorKind::BadRequestError(_inner) => _inner.fmt(f),
SearchIdentitiesErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SearchIdentitiesError {
fn code(&self) -> Option<&str> {
SearchIdentitiesError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
SearchIdentitiesErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
SearchIdentitiesErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl SearchIdentitiesError {
pub fn new(kind: SearchIdentitiesErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SearchIdentitiesErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SearchIdentitiesErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, SearchIdentitiesErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, SearchIdentitiesErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, SearchIdentitiesErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, SearchIdentitiesErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, SearchIdentitiesErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, SearchIdentitiesErrorKind::BadRequestError(_))
}
}
impl std::error::Error for SearchIdentitiesError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SearchIdentitiesErrorKind::InternalError(_inner) => Some(_inner),
SearchIdentitiesErrorKind::RateLimitError(_inner) => Some(_inner),
SearchIdentitiesErrorKind::ForbiddenError(_inner) => Some(_inner),
SearchIdentitiesErrorKind::UnauthorizedError(_inner) => Some(_inner),
SearchIdentitiesErrorKind::NotFoundError(_inner) => Some(_inner),
SearchIdentitiesErrorKind::BadRequestError(_inner) => Some(_inner),
SearchIdentitiesErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SetIdentityGameActivityError {
pub kind: SetIdentityGameActivityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SetIdentityGameActivityErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for SetIdentityGameActivityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SetIdentityGameActivityErrorKind::InternalError(_inner) => _inner.fmt(f),
SetIdentityGameActivityErrorKind::RateLimitError(_inner) => _inner.fmt(f),
SetIdentityGameActivityErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
SetIdentityGameActivityErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
SetIdentityGameActivityErrorKind::NotFoundError(_inner) => _inner.fmt(f),
SetIdentityGameActivityErrorKind::BadRequestError(_inner) => _inner.fmt(f),
SetIdentityGameActivityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SetIdentityGameActivityError {
fn code(&self) -> Option<&str> {
SetIdentityGameActivityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
SetIdentityGameActivityErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
SetIdentityGameActivityErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl SetIdentityGameActivityError {
pub fn new(kind: SetIdentityGameActivityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SetIdentityGameActivityErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SetIdentityGameActivityErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(
&self.kind,
SetIdentityGameActivityErrorKind::InternalError(_)
)
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
SetIdentityGameActivityErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
SetIdentityGameActivityErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
SetIdentityGameActivityErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(
&self.kind,
SetIdentityGameActivityErrorKind::NotFoundError(_)
)
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
SetIdentityGameActivityErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for SetIdentityGameActivityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SetIdentityGameActivityErrorKind::InternalError(_inner) => Some(_inner),
SetIdentityGameActivityErrorKind::RateLimitError(_inner) => Some(_inner),
SetIdentityGameActivityErrorKind::ForbiddenError(_inner) => Some(_inner),
SetIdentityGameActivityErrorKind::UnauthorizedError(_inner) => Some(_inner),
SetIdentityGameActivityErrorKind::NotFoundError(_inner) => Some(_inner),
SetIdentityGameActivityErrorKind::BadRequestError(_inner) => Some(_inner),
SetIdentityGameActivityErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SetupIdentityError {
pub kind: SetupIdentityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SetupIdentityErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for SetupIdentityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SetupIdentityErrorKind::InternalError(_inner) => _inner.fmt(f),
SetupIdentityErrorKind::RateLimitError(_inner) => _inner.fmt(f),
SetupIdentityErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
SetupIdentityErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
SetupIdentityErrorKind::NotFoundError(_inner) => _inner.fmt(f),
SetupIdentityErrorKind::BadRequestError(_inner) => _inner.fmt(f),
SetupIdentityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SetupIdentityError {
fn code(&self) -> Option<&str> {
SetupIdentityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
SetupIdentityErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
SetupIdentityErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl SetupIdentityError {
pub fn new(kind: SetupIdentityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SetupIdentityErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SetupIdentityErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, SetupIdentityErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, SetupIdentityErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, SetupIdentityErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, SetupIdentityErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, SetupIdentityErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, SetupIdentityErrorKind::BadRequestError(_))
}
}
impl std::error::Error for SetupIdentityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SetupIdentityErrorKind::InternalError(_inner) => Some(_inner),
SetupIdentityErrorKind::RateLimitError(_inner) => Some(_inner),
SetupIdentityErrorKind::ForbiddenError(_inner) => Some(_inner),
SetupIdentityErrorKind::UnauthorizedError(_inner) => Some(_inner),
SetupIdentityErrorKind::NotFoundError(_inner) => Some(_inner),
SetupIdentityErrorKind::BadRequestError(_inner) => Some(_inner),
SetupIdentityErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct SignupForBetaError {
pub kind: SignupForBetaErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum SignupForBetaErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for SignupForBetaError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
SignupForBetaErrorKind::InternalError(_inner) => _inner.fmt(f),
SignupForBetaErrorKind::RateLimitError(_inner) => _inner.fmt(f),
SignupForBetaErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
SignupForBetaErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
SignupForBetaErrorKind::NotFoundError(_inner) => _inner.fmt(f),
SignupForBetaErrorKind::BadRequestError(_inner) => _inner.fmt(f),
SignupForBetaErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for SignupForBetaError {
fn code(&self) -> Option<&str> {
SignupForBetaError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
SignupForBetaErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
SignupForBetaErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl SignupForBetaError {
pub fn new(kind: SignupForBetaErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: SignupForBetaErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: SignupForBetaErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, SignupForBetaErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, SignupForBetaErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, SignupForBetaErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, SignupForBetaErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, SignupForBetaErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, SignupForBetaErrorKind::BadRequestError(_))
}
}
impl std::error::Error for SignupForBetaError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
SignupForBetaErrorKind::InternalError(_inner) => Some(_inner),
SignupForBetaErrorKind::RateLimitError(_inner) => Some(_inner),
SignupForBetaErrorKind::ForbiddenError(_inner) => Some(_inner),
SignupForBetaErrorKind::UnauthorizedError(_inner) => Some(_inner),
SignupForBetaErrorKind::NotFoundError(_inner) => Some(_inner),
SignupForBetaErrorKind::BadRequestError(_inner) => Some(_inner),
SignupForBetaErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UnfollowIdentityError {
pub kind: UnfollowIdentityErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UnfollowIdentityErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for UnfollowIdentityError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UnfollowIdentityErrorKind::InternalError(_inner) => _inner.fmt(f),
UnfollowIdentityErrorKind::RateLimitError(_inner) => _inner.fmt(f),
UnfollowIdentityErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
UnfollowIdentityErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
UnfollowIdentityErrorKind::NotFoundError(_inner) => _inner.fmt(f),
UnfollowIdentityErrorKind::BadRequestError(_inner) => _inner.fmt(f),
UnfollowIdentityErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UnfollowIdentityError {
fn code(&self) -> Option<&str> {
UnfollowIdentityError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
UnfollowIdentityErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
UnfollowIdentityErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl UnfollowIdentityError {
pub fn new(kind: UnfollowIdentityErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: UnfollowIdentityErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UnfollowIdentityErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, UnfollowIdentityErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, UnfollowIdentityErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, UnfollowIdentityErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, UnfollowIdentityErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, UnfollowIdentityErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, UnfollowIdentityErrorKind::BadRequestError(_))
}
}
impl std::error::Error for UnfollowIdentityError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UnfollowIdentityErrorKind::InternalError(_inner) => Some(_inner),
UnfollowIdentityErrorKind::RateLimitError(_inner) => Some(_inner),
UnfollowIdentityErrorKind::ForbiddenError(_inner) => Some(_inner),
UnfollowIdentityErrorKind::UnauthorizedError(_inner) => Some(_inner),
UnfollowIdentityErrorKind::NotFoundError(_inner) => Some(_inner),
UnfollowIdentityErrorKind::BadRequestError(_inner) => Some(_inner),
UnfollowIdentityErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateIdentityProfileError {
pub kind: UpdateIdentityProfileErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateIdentityProfileErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for UpdateIdentityProfileError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateIdentityProfileErrorKind::InternalError(_inner) => _inner.fmt(f),
UpdateIdentityProfileErrorKind::RateLimitError(_inner) => _inner.fmt(f),
UpdateIdentityProfileErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
UpdateIdentityProfileErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
UpdateIdentityProfileErrorKind::NotFoundError(_inner) => _inner.fmt(f),
UpdateIdentityProfileErrorKind::BadRequestError(_inner) => _inner.fmt(f),
UpdateIdentityProfileErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateIdentityProfileError {
fn code(&self) -> Option<&str> {
UpdateIdentityProfileError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
UpdateIdentityProfileErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
UpdateIdentityProfileErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl UpdateIdentityProfileError {
pub fn new(kind: UpdateIdentityProfileErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: UpdateIdentityProfileErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateIdentityProfileErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, UpdateIdentityProfileErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
UpdateIdentityProfileErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
UpdateIdentityProfileErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
UpdateIdentityProfileErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, UpdateIdentityProfileErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
UpdateIdentityProfileErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for UpdateIdentityProfileError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateIdentityProfileErrorKind::InternalError(_inner) => Some(_inner),
UpdateIdentityProfileErrorKind::RateLimitError(_inner) => Some(_inner),
UpdateIdentityProfileErrorKind::ForbiddenError(_inner) => Some(_inner),
UpdateIdentityProfileErrorKind::UnauthorizedError(_inner) => Some(_inner),
UpdateIdentityProfileErrorKind::NotFoundError(_inner) => Some(_inner),
UpdateIdentityProfileErrorKind::BadRequestError(_inner) => Some(_inner),
UpdateIdentityProfileErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct UpdateIdentityStatusError {
pub kind: UpdateIdentityStatusErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum UpdateIdentityStatusErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for UpdateIdentityStatusError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
UpdateIdentityStatusErrorKind::InternalError(_inner) => _inner.fmt(f),
UpdateIdentityStatusErrorKind::RateLimitError(_inner) => _inner.fmt(f),
UpdateIdentityStatusErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
UpdateIdentityStatusErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
UpdateIdentityStatusErrorKind::NotFoundError(_inner) => _inner.fmt(f),
UpdateIdentityStatusErrorKind::BadRequestError(_inner) => _inner.fmt(f),
UpdateIdentityStatusErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for UpdateIdentityStatusError {
fn code(&self) -> Option<&str> {
UpdateIdentityStatusError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
UpdateIdentityStatusErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
UpdateIdentityStatusErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl UpdateIdentityStatusError {
pub fn new(kind: UpdateIdentityStatusErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: UpdateIdentityStatusErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: UpdateIdentityStatusErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, UpdateIdentityStatusErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, UpdateIdentityStatusErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, UpdateIdentityStatusErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
UpdateIdentityStatusErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, UpdateIdentityStatusErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
UpdateIdentityStatusErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for UpdateIdentityStatusError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
UpdateIdentityStatusErrorKind::InternalError(_inner) => Some(_inner),
UpdateIdentityStatusErrorKind::RateLimitError(_inner) => Some(_inner),
UpdateIdentityStatusErrorKind::ForbiddenError(_inner) => Some(_inner),
UpdateIdentityStatusErrorKind::UnauthorizedError(_inner) => Some(_inner),
UpdateIdentityStatusErrorKind::NotFoundError(_inner) => Some(_inner),
UpdateIdentityStatusErrorKind::BadRequestError(_inner) => Some(_inner),
UpdateIdentityStatusErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct ValidateIdentityProfileError {
pub kind: ValidateIdentityProfileErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum ValidateIdentityProfileErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for ValidateIdentityProfileError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
ValidateIdentityProfileErrorKind::InternalError(_inner) => _inner.fmt(f),
ValidateIdentityProfileErrorKind::RateLimitError(_inner) => _inner.fmt(f),
ValidateIdentityProfileErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
ValidateIdentityProfileErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
ValidateIdentityProfileErrorKind::NotFoundError(_inner) => _inner.fmt(f),
ValidateIdentityProfileErrorKind::BadRequestError(_inner) => _inner.fmt(f),
ValidateIdentityProfileErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for ValidateIdentityProfileError {
fn code(&self) -> Option<&str> {
ValidateIdentityProfileError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
ValidateIdentityProfileErrorKind::InternalError(inner) => {
Some(inner.retryable_error_kind())
}
ValidateIdentityProfileErrorKind::UnauthorizedError(inner) => {
Some(inner.retryable_error_kind())
}
_ => None,
}
}
}
impl ValidateIdentityProfileError {
pub fn new(kind: ValidateIdentityProfileErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: ValidateIdentityProfileErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: ValidateIdentityProfileErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(
&self.kind,
ValidateIdentityProfileErrorKind::InternalError(_)
)
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(
&self.kind,
ValidateIdentityProfileErrorKind::RateLimitError(_)
)
}
pub fn is_forbidden_error(&self) -> bool {
matches!(
&self.kind,
ValidateIdentityProfileErrorKind::ForbiddenError(_)
)
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(
&self.kind,
ValidateIdentityProfileErrorKind::UnauthorizedError(_)
)
}
pub fn is_not_found_error(&self) -> bool {
matches!(
&self.kind,
ValidateIdentityProfileErrorKind::NotFoundError(_)
)
}
pub fn is_bad_request_error(&self) -> bool {
matches!(
&self.kind,
ValidateIdentityProfileErrorKind::BadRequestError(_)
)
}
}
impl std::error::Error for ValidateIdentityProfileError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
ValidateIdentityProfileErrorKind::InternalError(_inner) => Some(_inner),
ValidateIdentityProfileErrorKind::RateLimitError(_inner) => Some(_inner),
ValidateIdentityProfileErrorKind::ForbiddenError(_inner) => Some(_inner),
ValidateIdentityProfileErrorKind::UnauthorizedError(_inner) => Some(_inner),
ValidateIdentityProfileErrorKind::NotFoundError(_inner) => Some(_inner),
ValidateIdentityProfileErrorKind::BadRequestError(_inner) => Some(_inner),
ValidateIdentityProfileErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub struct WatchEventsError {
pub kind: WatchEventsErrorKind,
pub(crate) meta: aws_smithy_types::Error,
}
#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum WatchEventsErrorKind {
InternalError(crate::error::InternalError),
RateLimitError(crate::error::RateLimitError),
ForbiddenError(crate::error::ForbiddenError),
UnauthorizedError(crate::error::UnauthorizedError),
NotFoundError(crate::error::NotFoundError),
BadRequestError(crate::error::BadRequestError),
Unhandled(Box<dyn std::error::Error + Send + Sync + 'static>),
}
impl std::fmt::Display for WatchEventsError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match &self.kind {
WatchEventsErrorKind::InternalError(_inner) => _inner.fmt(f),
WatchEventsErrorKind::RateLimitError(_inner) => _inner.fmt(f),
WatchEventsErrorKind::ForbiddenError(_inner) => _inner.fmt(f),
WatchEventsErrorKind::UnauthorizedError(_inner) => _inner.fmt(f),
WatchEventsErrorKind::NotFoundError(_inner) => _inner.fmt(f),
WatchEventsErrorKind::BadRequestError(_inner) => _inner.fmt(f),
WatchEventsErrorKind::Unhandled(_inner) => _inner.fmt(f),
}
}
}
impl aws_smithy_types::retry::ProvideErrorKind for WatchEventsError {
fn code(&self) -> Option<&str> {
WatchEventsError::code(self)
}
fn retryable_error_kind(&self) -> Option<aws_smithy_types::retry::ErrorKind> {
match &self.kind {
WatchEventsErrorKind::InternalError(inner) => Some(inner.retryable_error_kind()),
WatchEventsErrorKind::UnauthorizedError(inner) => Some(inner.retryable_error_kind()),
_ => None,
}
}
}
impl WatchEventsError {
pub fn new(kind: WatchEventsErrorKind, meta: aws_smithy_types::Error) -> Self {
Self { kind, meta }
}
pub fn unhandled(err: impl Into<Box<dyn std::error::Error + Send + Sync + 'static>>) -> Self {
Self {
kind: WatchEventsErrorKind::Unhandled(err.into()),
meta: Default::default(),
}
}
pub fn generic(err: aws_smithy_types::Error) -> Self {
Self {
meta: err.clone(),
kind: WatchEventsErrorKind::Unhandled(err.into()),
}
}
pub fn message(&self) -> Option<&str> {
self.meta.message()
}
pub fn meta(&self) -> &aws_smithy_types::Error {
&self.meta
}
pub fn request_id(&self) -> Option<&str> {
self.meta.request_id()
}
pub fn code(&self) -> Option<&str> {
self.meta.code()
}
pub fn is_internal_error(&self) -> bool {
matches!(&self.kind, WatchEventsErrorKind::InternalError(_))
}
pub fn is_rate_limit_error(&self) -> bool {
matches!(&self.kind, WatchEventsErrorKind::RateLimitError(_))
}
pub fn is_forbidden_error(&self) -> bool {
matches!(&self.kind, WatchEventsErrorKind::ForbiddenError(_))
}
pub fn is_unauthorized_error(&self) -> bool {
matches!(&self.kind, WatchEventsErrorKind::UnauthorizedError(_))
}
pub fn is_not_found_error(&self) -> bool {
matches!(&self.kind, WatchEventsErrorKind::NotFoundError(_))
}
pub fn is_bad_request_error(&self) -> bool {
matches!(&self.kind, WatchEventsErrorKind::BadRequestError(_))
}
}
impl std::error::Error for WatchEventsError {
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
match &self.kind {
WatchEventsErrorKind::InternalError(_inner) => Some(_inner),
WatchEventsErrorKind::RateLimitError(_inner) => Some(_inner),
WatchEventsErrorKind::ForbiddenError(_inner) => Some(_inner),
WatchEventsErrorKind::UnauthorizedError(_inner) => Some(_inner),
WatchEventsErrorKind::NotFoundError(_inner) => Some(_inner),
WatchEventsErrorKind::BadRequestError(_inner) => Some(_inner),
WatchEventsErrorKind::Unhandled(_inner) => Some(_inner.as_ref()),
}
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct BadRequestError {
#[allow(missing_docs)] pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] pub message: std::option::Option<std::string::String>,
pub metadata: std::option::Option<aws_smithy_types::Document>,
}
impl BadRequestError {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
self.metadata.as_ref()
}
}
impl std::fmt::Debug for BadRequestError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("BadRequestError");
formatter.field("code", &self.code);
formatter.field("message", &self.message);
formatter.field("metadata", &self.metadata);
formatter.finish()
}
}
impl BadRequestError {
pub fn message(&self) -> Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for BadRequestError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "BadRequestError")?;
if let Some(inner_1) = &self.message {
write!(f, ": {}", inner_1)?;
}
Ok(())
}
}
impl std::error::Error for BadRequestError {}
pub mod bad_request_error {
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) metadata: std::option::Option<aws_smithy_types::Document>,
}
impl Builder {
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn metadata(mut self, input: aws_smithy_types::Document) -> Self {
self.metadata = Some(input);
self
}
pub fn set_metadata(
mut self,
input: std::option::Option<aws_smithy_types::Document>,
) -> Self {
self.metadata = input;
self
}
pub fn build(self) -> crate::error::BadRequestError {
crate::error::BadRequestError {
code: self.code,
message: self.message,
metadata: self.metadata,
}
}
}
}
impl BadRequestError {
pub fn builder() -> crate::error::bad_request_error::Builder {
crate::error::bad_request_error::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct NotFoundError {
#[allow(missing_docs)] pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] pub message: std::option::Option<std::string::String>,
pub metadata: std::option::Option<aws_smithy_types::Document>,
}
impl NotFoundError {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
self.metadata.as_ref()
}
}
impl std::fmt::Debug for NotFoundError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("NotFoundError");
formatter.field("code", &self.code);
formatter.field("message", &self.message);
formatter.field("metadata", &self.metadata);
formatter.finish()
}
}
impl NotFoundError {
pub fn message(&self) -> Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for NotFoundError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "NotFoundError")?;
if let Some(inner_2) = &self.message {
write!(f, ": {}", inner_2)?;
}
Ok(())
}
}
impl std::error::Error for NotFoundError {}
pub mod not_found_error {
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) metadata: std::option::Option<aws_smithy_types::Document>,
}
impl Builder {
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn metadata(mut self, input: aws_smithy_types::Document) -> Self {
self.metadata = Some(input);
self
}
pub fn set_metadata(
mut self,
input: std::option::Option<aws_smithy_types::Document>,
) -> Self {
self.metadata = input;
self
}
pub fn build(self) -> crate::error::NotFoundError {
crate::error::NotFoundError {
code: self.code,
message: self.message,
metadata: self.metadata,
}
}
}
}
impl NotFoundError {
pub fn builder() -> crate::error::not_found_error::Builder {
crate::error::not_found_error::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct UnauthorizedError {
#[allow(missing_docs)] pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] pub message: std::option::Option<std::string::String>,
pub metadata: std::option::Option<aws_smithy_types::Document>,
}
impl UnauthorizedError {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
self.metadata.as_ref()
}
}
impl std::fmt::Debug for UnauthorizedError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("UnauthorizedError");
formatter.field("code", &self.code);
formatter.field("message", &self.message);
formatter.field("metadata", &self.metadata);
formatter.finish()
}
}
impl UnauthorizedError {
pub fn retryable_error_kind(&self) -> aws_smithy_types::retry::ErrorKind {
aws_smithy_types::retry::ErrorKind::ClientError
}
pub fn message(&self) -> Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for UnauthorizedError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "UnauthorizedError")?;
if let Some(inner_3) = &self.message {
write!(f, ": {}", inner_3)?;
}
Ok(())
}
}
impl std::error::Error for UnauthorizedError {}
pub mod unauthorized_error {
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) metadata: std::option::Option<aws_smithy_types::Document>,
}
impl Builder {
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn metadata(mut self, input: aws_smithy_types::Document) -> Self {
self.metadata = Some(input);
self
}
pub fn set_metadata(
mut self,
input: std::option::Option<aws_smithy_types::Document>,
) -> Self {
self.metadata = input;
self
}
pub fn build(self) -> crate::error::UnauthorizedError {
crate::error::UnauthorizedError {
code: self.code,
message: self.message,
metadata: self.metadata,
}
}
}
}
impl UnauthorizedError {
pub fn builder() -> crate::error::unauthorized_error::Builder {
crate::error::unauthorized_error::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ForbiddenError {
#[allow(missing_docs)] pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] pub message: std::option::Option<std::string::String>,
pub metadata: std::option::Option<aws_smithy_types::Document>,
}
impl ForbiddenError {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
self.metadata.as_ref()
}
}
impl std::fmt::Debug for ForbiddenError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ForbiddenError");
formatter.field("code", &self.code);
formatter.field("message", &self.message);
formatter.field("metadata", &self.metadata);
formatter.finish()
}
}
impl ForbiddenError {
pub fn message(&self) -> Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for ForbiddenError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ForbiddenError")?;
if let Some(inner_4) = &self.message {
write!(f, ": {}", inner_4)?;
}
Ok(())
}
}
impl std::error::Error for ForbiddenError {}
pub mod forbidden_error {
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) metadata: std::option::Option<aws_smithy_types::Document>,
}
impl Builder {
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn metadata(mut self, input: aws_smithy_types::Document) -> Self {
self.metadata = Some(input);
self
}
pub fn set_metadata(
mut self,
input: std::option::Option<aws_smithy_types::Document>,
) -> Self {
self.metadata = input;
self
}
pub fn build(self) -> crate::error::ForbiddenError {
crate::error::ForbiddenError {
code: self.code,
message: self.message,
metadata: self.metadata,
}
}
}
}
impl ForbiddenError {
pub fn builder() -> crate::error::forbidden_error::Builder {
crate::error::forbidden_error::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct RateLimitError {
#[allow(missing_docs)] pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] pub message: std::option::Option<std::string::String>,
pub metadata: std::option::Option<aws_smithy_types::Document>,
}
impl RateLimitError {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
self.metadata.as_ref()
}
}
impl std::fmt::Debug for RateLimitError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("RateLimitError");
formatter.field("code", &self.code);
formatter.field("message", &self.message);
formatter.field("metadata", &self.metadata);
formatter.finish()
}
}
impl RateLimitError {
pub fn message(&self) -> Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for RateLimitError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "RateLimitError")?;
if let Some(inner_5) = &self.message {
write!(f, ": {}", inner_5)?;
}
Ok(())
}
}
impl std::error::Error for RateLimitError {}
pub mod rate_limit_error {
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) metadata: std::option::Option<aws_smithy_types::Document>,
}
impl Builder {
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn metadata(mut self, input: aws_smithy_types::Document) -> Self {
self.metadata = Some(input);
self
}
pub fn set_metadata(
mut self,
input: std::option::Option<aws_smithy_types::Document>,
) -> Self {
self.metadata = input;
self
}
pub fn build(self) -> crate::error::RateLimitError {
crate::error::RateLimitError {
code: self.code,
message: self.message,
metadata: self.metadata,
}
}
}
}
impl RateLimitError {
pub fn builder() -> crate::error::rate_limit_error::Builder {
crate::error::rate_limit_error::Builder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct InternalError {
#[allow(missing_docs)] pub code: std::option::Option<std::string::String>,
#[allow(missing_docs)] pub message: std::option::Option<std::string::String>,
pub metadata: std::option::Option<aws_smithy_types::Document>,
}
impl InternalError {
#[allow(missing_docs)] pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
pub fn metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
self.metadata.as_ref()
}
}
impl std::fmt::Debug for InternalError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("InternalError");
formatter.field("code", &self.code);
formatter.field("message", &self.message);
formatter.field("metadata", &self.metadata);
formatter.finish()
}
}
impl InternalError {
pub fn retryable_error_kind(&self) -> aws_smithy_types::retry::ErrorKind {
aws_smithy_types::retry::ErrorKind::ServerError
}
pub fn message(&self) -> Option<&str> {
self.message.as_deref()
}
}
impl std::fmt::Display for InternalError {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "InternalError")?;
if let Some(inner_6) = &self.message {
write!(f, ": {}", inner_6)?;
}
Ok(())
}
}
impl std::error::Error for InternalError {}
pub mod internal_error {
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) metadata: std::option::Option<aws_smithy_types::Document>,
}
impl Builder {
#[allow(missing_docs)] pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
#[allow(missing_docs)] pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
pub fn metadata(mut self, input: aws_smithy_types::Document) -> Self {
self.metadata = Some(input);
self
}
pub fn set_metadata(
mut self,
input: std::option::Option<aws_smithy_types::Document>,
) -> Self {
self.metadata = input;
self
}
pub fn build(self) -> crate::error::InternalError {
crate::error::InternalError {
code: self.code,
message: self.message,
metadata: self.metadata,
}
}
}
}
impl InternalError {
pub fn builder() -> crate::error::internal_error::Builder {
crate::error::internal_error::Builder::default()
}
}