#[non_exhaustive]
#[derive(::std::fmt::Debug)]
pub enum Error {
AccessDeniedException(crate::types::error::AccessDeniedException),
BadRequestException(crate::types::error::BadRequestException),
ConflictException(crate::types::error::ConflictException),
InternalFailureException(crate::types::error::InternalFailureException),
LimitExceededException(crate::types::error::LimitExceededException),
NotFoundException(crate::types::error::NotFoundException),
PreconditionFailedException(crate::types::error::PreconditionFailedException),
ResourceInUseException(crate::types::error::ResourceInUseException),
#[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
variable wildcard pattern and check `.code()`:
\
`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
\
See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-Error) for what information is available for the error.")]
Unhandled(crate::error::sealed_unhandled::Unhandled),
}
impl ::std::fmt::Display for Error {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Error::AccessDeniedException(inner) => inner.fmt(f),
Error::BadRequestException(inner) => inner.fmt(f),
Error::ConflictException(inner) => inner.fmt(f),
Error::InternalFailureException(inner) => inner.fmt(f),
Error::LimitExceededException(inner) => inner.fmt(f),
Error::NotFoundException(inner) => inner.fmt(f),
Error::PreconditionFailedException(inner) => inner.fmt(f),
Error::ResourceInUseException(inner) => inner.fmt(f),
Error::Unhandled(_) => {
if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
write!(f, "unhandled error ({code})")
} else {
f.write_str("unhandled error")
}
}
}
}
}
impl From<::aws_smithy_types::error::operation::BuildError> for Error {
fn from(value: ::aws_smithy_types::error::operation::BuildError) -> Self {
Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
source: value.into(),
meta: ::std::default::Default::default(),
})
}
}
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for Error {
fn meta(&self) -> &::aws_smithy_types::error::metadata::ErrorMetadata {
match self {
Self::AccessDeniedException(inner) => inner.meta(),
Self::BadRequestException(inner) => inner.meta(),
Self::ConflictException(inner) => inner.meta(),
Self::InternalFailureException(inner) => inner.meta(),
Self::LimitExceededException(inner) => inner.meta(),
Self::NotFoundException(inner) => inner.meta(),
Self::PreconditionFailedException(inner) => inner.meta(),
Self::ResourceInUseException(inner) => inner.meta(),
Self::Unhandled(inner) => &inner.meta,
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_bot_version::CreateBotVersionError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_bot_version::CreateBotVersionError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::create_bot_version::CreateBotVersionError> for Error {
fn from(err: crate::operation::create_bot_version::CreateBotVersionError) -> Self {
match err {
crate::operation::create_bot_version::CreateBotVersionError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_bot_version::CreateBotVersionError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_bot_version::CreateBotVersionError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::create_bot_version::CreateBotVersionError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::create_bot_version::CreateBotVersionError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_bot_version::CreateBotVersionError::PreconditionFailedException(inner) => {
Error::PreconditionFailedException(inner)
}
crate::operation::create_bot_version::CreateBotVersionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_intent_version::CreateIntentVersionError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_intent_version::CreateIntentVersionError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::create_intent_version::CreateIntentVersionError> for Error {
fn from(err: crate::operation::create_intent_version::CreateIntentVersionError) -> Self {
match err {
crate::operation::create_intent_version::CreateIntentVersionError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_intent_version::CreateIntentVersionError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_intent_version::CreateIntentVersionError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::create_intent_version::CreateIntentVersionError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::create_intent_version::CreateIntentVersionError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_intent_version::CreateIntentVersionError::PreconditionFailedException(inner) => {
Error::PreconditionFailedException(inner)
}
crate::operation::create_intent_version::CreateIntentVersionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_slot_type_version::CreateSlotTypeVersionError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_slot_type_version::CreateSlotTypeVersionError, R>,
) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::create_slot_type_version::CreateSlotTypeVersionError> for Error {
fn from(err: crate::operation::create_slot_type_version::CreateSlotTypeVersionError) -> Self {
match err {
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::LimitExceededException(inner) => {
Error::LimitExceededException(inner)
}
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::PreconditionFailedException(inner) => {
Error::PreconditionFailedException(inner)
}
crate::operation::create_slot_type_version::CreateSlotTypeVersionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot::DeleteBotError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot::DeleteBotError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_bot::DeleteBotError> for Error {
fn from(err: crate::operation::delete_bot::DeleteBotError) -> Self {
match err {
crate::operation::delete_bot::DeleteBotError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_bot::DeleteBotError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_bot::DeleteBotError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::delete_bot::DeleteBotError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_bot::DeleteBotError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_bot::DeleteBotError::ResourceInUseException(inner) => Error::ResourceInUseException(inner),
crate::operation::delete_bot::DeleteBotError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot_alias::DeleteBotAliasError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot_alias::DeleteBotAliasError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_bot_alias::DeleteBotAliasError> for Error {
fn from(err: crate::operation::delete_bot_alias::DeleteBotAliasError) -> Self {
match err {
crate::operation::delete_bot_alias::DeleteBotAliasError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_bot_alias::DeleteBotAliasError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_bot_alias::DeleteBotAliasError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::delete_bot_alias::DeleteBotAliasError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_bot_alias::DeleteBotAliasError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_bot_alias::DeleteBotAliasError::ResourceInUseException(inner) => Error::ResourceInUseException(inner),
crate::operation::delete_bot_alias::DeleteBotAliasError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_runtime_api::client::result::SdkError<
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError,
R,
>,
) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError> for Error {
fn from(err: crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError) -> Self {
match err {
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError::LimitExceededException(inner) => {
Error::LimitExceededException(inner)
}
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::delete_bot_channel_association::DeleteBotChannelAssociationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot_version::DeleteBotVersionError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_bot_version::DeleteBotVersionError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_bot_version::DeleteBotVersionError> for Error {
fn from(err: crate::operation::delete_bot_version::DeleteBotVersionError) -> Self {
match err {
crate::operation::delete_bot_version::DeleteBotVersionError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_bot_version::DeleteBotVersionError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_bot_version::DeleteBotVersionError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::delete_bot_version::DeleteBotVersionError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_bot_version::DeleteBotVersionError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_bot_version::DeleteBotVersionError::ResourceInUseException(inner) => Error::ResourceInUseException(inner),
crate::operation::delete_bot_version::DeleteBotVersionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_intent::DeleteIntentError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_intent::DeleteIntentError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_intent::DeleteIntentError> for Error {
fn from(err: crate::operation::delete_intent::DeleteIntentError) -> Self {
match err {
crate::operation::delete_intent::DeleteIntentError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_intent::DeleteIntentError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_intent::DeleteIntentError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::delete_intent::DeleteIntentError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_intent::DeleteIntentError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_intent::DeleteIntentError::ResourceInUseException(inner) => Error::ResourceInUseException(inner),
crate::operation::delete_intent::DeleteIntentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_intent_version::DeleteIntentVersionError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_intent_version::DeleteIntentVersionError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_intent_version::DeleteIntentVersionError> for Error {
fn from(err: crate::operation::delete_intent_version::DeleteIntentVersionError) -> Self {
match err {
crate::operation::delete_intent_version::DeleteIntentVersionError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_intent_version::DeleteIntentVersionError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_intent_version::DeleteIntentVersionError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::delete_intent_version::DeleteIntentVersionError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_intent_version::DeleteIntentVersionError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_intent_version::DeleteIntentVersionError::ResourceInUseException(inner) => Error::ResourceInUseException(inner),
crate::operation::delete_intent_version::DeleteIntentVersionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_slot_type::DeleteSlotTypeError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_slot_type::DeleteSlotTypeError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_slot_type::DeleteSlotTypeError> for Error {
fn from(err: crate::operation::delete_slot_type::DeleteSlotTypeError) -> Self {
match err {
crate::operation::delete_slot_type::DeleteSlotTypeError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_slot_type::DeleteSlotTypeError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_slot_type::DeleteSlotTypeError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::delete_slot_type::DeleteSlotTypeError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_slot_type::DeleteSlotTypeError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_slot_type::DeleteSlotTypeError::ResourceInUseException(inner) => Error::ResourceInUseException(inner),
crate::operation::delete_slot_type::DeleteSlotTypeError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError, R>,
) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError> for Error {
fn from(err: crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError) -> Self {
match err {
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::LimitExceededException(inner) => {
Error::LimitExceededException(inner)
}
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::ResourceInUseException(inner) => {
Error::ResourceInUseException(inner)
}
crate::operation::delete_slot_type_version::DeleteSlotTypeVersionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_utterances::DeleteUtterancesError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_utterances::DeleteUtterancesError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::delete_utterances::DeleteUtterancesError> for Error {
fn from(err: crate::operation::delete_utterances::DeleteUtterancesError) -> Self {
match err {
crate::operation::delete_utterances::DeleteUtterancesError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_utterances::DeleteUtterancesError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::delete_utterances::DeleteUtterancesError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::delete_utterances::DeleteUtterancesError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_utterances::DeleteUtterancesError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot::GetBotError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot::GetBotError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bot::GetBotError> for Error {
fn from(err: crate::operation::get_bot::GetBotError) -> Self {
match err {
crate::operation::get_bot::GetBotError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_bot::GetBotError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_bot::GetBotError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_bot::GetBotError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_bot::GetBotError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_alias::GetBotAliasError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_alias::GetBotAliasError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bot_alias::GetBotAliasError> for Error {
fn from(err: crate::operation::get_bot_alias::GetBotAliasError) -> Self {
match err {
crate::operation::get_bot_alias::GetBotAliasError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_bot_alias::GetBotAliasError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_bot_alias::GetBotAliasError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_bot_alias::GetBotAliasError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_bot_alias::GetBotAliasError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_aliases::GetBotAliasesError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_aliases::GetBotAliasesError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bot_aliases::GetBotAliasesError> for Error {
fn from(err: crate::operation::get_bot_aliases::GetBotAliasesError) -> Self {
match err {
crate::operation::get_bot_aliases::GetBotAliasesError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_bot_aliases::GetBotAliasesError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_bot_aliases::GetBotAliasesError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_bot_aliases::GetBotAliasesError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_channel_association::GetBotChannelAssociationError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_channel_association::GetBotChannelAssociationError, R>,
) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bot_channel_association::GetBotChannelAssociationError> for Error {
fn from(err: crate::operation::get_bot_channel_association::GetBotChannelAssociationError) -> Self {
match err {
crate::operation::get_bot_channel_association::GetBotChannelAssociationError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_bot_channel_association::GetBotChannelAssociationError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::get_bot_channel_association::GetBotChannelAssociationError::LimitExceededException(inner) => {
Error::LimitExceededException(inner)
}
crate::operation::get_bot_channel_association::GetBotChannelAssociationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_bot_channel_association::GetBotChannelAssociationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError, R>,
) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError> for Error {
fn from(err: crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError) -> Self {
match err {
crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError::LimitExceededException(inner) => {
Error::LimitExceededException(inner)
}
crate::operation::get_bot_channel_associations::GetBotChannelAssociationsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bots::GetBotsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bots::GetBotsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bots::GetBotsError> for Error {
fn from(err: crate::operation::get_bots::GetBotsError) -> Self {
match err {
crate::operation::get_bots::GetBotsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_bots::GetBotsError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_bots::GetBotsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_bots::GetBotsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_bots::GetBotsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_versions::GetBotVersionsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_bot_versions::GetBotVersionsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_bot_versions::GetBotVersionsError> for Error {
fn from(err: crate::operation::get_bot_versions::GetBotVersionsError) -> Self {
match err {
crate::operation::get_bot_versions::GetBotVersionsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_bot_versions::GetBotVersionsError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_bot_versions::GetBotVersionsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_bot_versions::GetBotVersionsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_bot_versions::GetBotVersionsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_builtin_intent::GetBuiltinIntentError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_builtin_intent::GetBuiltinIntentError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_builtin_intent::GetBuiltinIntentError> for Error {
fn from(err: crate::operation::get_builtin_intent::GetBuiltinIntentError) -> Self {
match err {
crate::operation::get_builtin_intent::GetBuiltinIntentError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_builtin_intent::GetBuiltinIntentError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_builtin_intent::GetBuiltinIntentError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_builtin_intent::GetBuiltinIntentError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_builtin_intent::GetBuiltinIntentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_builtin_intents::GetBuiltinIntentsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_builtin_intents::GetBuiltinIntentsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_builtin_intents::GetBuiltinIntentsError> for Error {
fn from(err: crate::operation::get_builtin_intents::GetBuiltinIntentsError) -> Self {
match err {
crate::operation::get_builtin_intents::GetBuiltinIntentsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_builtin_intents::GetBuiltinIntentsError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_builtin_intents::GetBuiltinIntentsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_builtin_intents::GetBuiltinIntentsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError> for Error {
fn from(err: crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError) -> Self {
match err {
crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_builtin_slot_types::GetBuiltinSlotTypesError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_export::GetExportError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_export::GetExportError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_export::GetExportError> for Error {
fn from(err: crate::operation::get_export::GetExportError) -> Self {
match err {
crate::operation::get_export::GetExportError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_export::GetExportError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_export::GetExportError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_export::GetExportError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_export::GetExportError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_import::GetImportError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_import::GetImportError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_import::GetImportError> for Error {
fn from(err: crate::operation::get_import::GetImportError) -> Self {
match err {
crate::operation::get_import::GetImportError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_import::GetImportError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_import::GetImportError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_import::GetImportError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_import::GetImportError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_intent::GetIntentError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_intent::GetIntentError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_intent::GetIntentError> for Error {
fn from(err: crate::operation::get_intent::GetIntentError) -> Self {
match err {
crate::operation::get_intent::GetIntentError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_intent::GetIntentError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_intent::GetIntentError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_intent::GetIntentError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_intent::GetIntentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_intents::GetIntentsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_intents::GetIntentsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_intents::GetIntentsError> for Error {
fn from(err: crate::operation::get_intents::GetIntentsError) -> Self {
match err {
crate::operation::get_intents::GetIntentsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_intents::GetIntentsError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_intents::GetIntentsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_intents::GetIntentsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_intents::GetIntentsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_intent_versions::GetIntentVersionsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_intent_versions::GetIntentVersionsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_intent_versions::GetIntentVersionsError> for Error {
fn from(err: crate::operation::get_intent_versions::GetIntentVersionsError) -> Self {
match err {
crate::operation::get_intent_versions::GetIntentVersionsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_intent_versions::GetIntentVersionsError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_intent_versions::GetIntentVersionsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_intent_versions::GetIntentVersionsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_intent_versions::GetIntentVersionsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_migration::GetMigrationError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_migration::GetMigrationError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_migration::GetMigrationError> for Error {
fn from(err: crate::operation::get_migration::GetMigrationError) -> Self {
match err {
crate::operation::get_migration::GetMigrationError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_migration::GetMigrationError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_migration::GetMigrationError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_migration::GetMigrationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_migration::GetMigrationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_migrations::GetMigrationsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_migrations::GetMigrationsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_migrations::GetMigrationsError> for Error {
fn from(err: crate::operation::get_migrations::GetMigrationsError) -> Self {
match err {
crate::operation::get_migrations::GetMigrationsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_migrations::GetMigrationsError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_migrations::GetMigrationsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_migrations::GetMigrationsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_slot_type::GetSlotTypeError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_slot_type::GetSlotTypeError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_slot_type::GetSlotTypeError> for Error {
fn from(err: crate::operation::get_slot_type::GetSlotTypeError) -> Self {
match err {
crate::operation::get_slot_type::GetSlotTypeError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_slot_type::GetSlotTypeError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_slot_type::GetSlotTypeError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_slot_type::GetSlotTypeError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_slot_type::GetSlotTypeError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_slot_types::GetSlotTypesError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_slot_types::GetSlotTypesError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_slot_types::GetSlotTypesError> for Error {
fn from(err: crate::operation::get_slot_types::GetSlotTypesError) -> Self {
match err {
crate::operation::get_slot_types::GetSlotTypesError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_slot_types::GetSlotTypesError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_slot_types::GetSlotTypesError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_slot_types::GetSlotTypesError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_slot_types::GetSlotTypesError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_slot_type_versions::GetSlotTypeVersionsError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_slot_type_versions::GetSlotTypeVersionsError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_slot_type_versions::GetSlotTypeVersionsError> for Error {
fn from(err: crate::operation::get_slot_type_versions::GetSlotTypeVersionsError) -> Self {
match err {
crate::operation::get_slot_type_versions::GetSlotTypeVersionsError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_slot_type_versions::GetSlotTypeVersionsError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::get_slot_type_versions::GetSlotTypeVersionsError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_slot_type_versions::GetSlotTypeVersionsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_slot_type_versions::GetSlotTypeVersionsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_utterances_view::GetUtterancesViewError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_utterances_view::GetUtterancesViewError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::get_utterances_view::GetUtterancesViewError> for Error {
fn from(err: crate::operation::get_utterances_view::GetUtterancesViewError) -> Self {
match err {
crate::operation::get_utterances_view::GetUtterancesViewError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_utterances_view::GetUtterancesViewError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::get_utterances_view::GetUtterancesViewError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::get_utterances_view::GetUtterancesViewError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_tags_for_resource::ListTagsForResourceError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_tags_for_resource::ListTagsForResourceError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::list_tags_for_resource::ListTagsForResourceError> for Error {
fn from(err: crate::operation::list_tags_for_resource::ListTagsForResourceError) -> Self {
match err {
crate::operation::list_tags_for_resource::ListTagsForResourceError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::list_tags_for_resource::ListTagsForResourceError::InternalFailureException(inner) => {
Error::InternalFailureException(inner)
}
crate::operation::list_tags_for_resource::ListTagsForResourceError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::list_tags_for_resource::ListTagsForResourceError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::list_tags_for_resource::ListTagsForResourceError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_bot::PutBotError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_bot::PutBotError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::put_bot::PutBotError> for Error {
fn from(err: crate::operation::put_bot::PutBotError) -> Self {
match err {
crate::operation::put_bot::PutBotError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::put_bot::PutBotError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::put_bot::PutBotError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::put_bot::PutBotError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::put_bot::PutBotError::PreconditionFailedException(inner) => Error::PreconditionFailedException(inner),
crate::operation::put_bot::PutBotError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_bot_alias::PutBotAliasError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_bot_alias::PutBotAliasError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::put_bot_alias::PutBotAliasError> for Error {
fn from(err: crate::operation::put_bot_alias::PutBotAliasError) -> Self {
match err {
crate::operation::put_bot_alias::PutBotAliasError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::put_bot_alias::PutBotAliasError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::put_bot_alias::PutBotAliasError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::put_bot_alias::PutBotAliasError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::put_bot_alias::PutBotAliasError::PreconditionFailedException(inner) => Error::PreconditionFailedException(inner),
crate::operation::put_bot_alias::PutBotAliasError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_intent::PutIntentError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_intent::PutIntentError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::put_intent::PutIntentError> for Error {
fn from(err: crate::operation::put_intent::PutIntentError) -> Self {
match err {
crate::operation::put_intent::PutIntentError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::put_intent::PutIntentError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::put_intent::PutIntentError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::put_intent::PutIntentError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::put_intent::PutIntentError::PreconditionFailedException(inner) => Error::PreconditionFailedException(inner),
crate::operation::put_intent::PutIntentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_slot_type::PutSlotTypeError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_slot_type::PutSlotTypeError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::put_slot_type::PutSlotTypeError> for Error {
fn from(err: crate::operation::put_slot_type::PutSlotTypeError) -> Self {
match err {
crate::operation::put_slot_type::PutSlotTypeError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::put_slot_type::PutSlotTypeError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::put_slot_type::PutSlotTypeError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::put_slot_type::PutSlotTypeError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::put_slot_type::PutSlotTypeError::PreconditionFailedException(inner) => Error::PreconditionFailedException(inner),
crate::operation::put_slot_type::PutSlotTypeError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::start_import::StartImportError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::start_import::StartImportError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::start_import::StartImportError> for Error {
fn from(err: crate::operation::start_import::StartImportError) -> Self {
match err {
crate::operation::start_import::StartImportError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::start_import::StartImportError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::start_import::StartImportError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::start_import::StartImportError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::start_migration::StartMigrationError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::start_migration::StartMigrationError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::start_migration::StartMigrationError> for Error {
fn from(err: crate::operation::start_migration::StartMigrationError) -> Self {
match err {
crate::operation::start_migration::StartMigrationError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
crate::operation::start_migration::StartMigrationError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::start_migration::StartMigrationError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::start_migration::StartMigrationError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::start_migration::StartMigrationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::start_migration::StartMigrationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::tag_resource::TagResourceError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::tag_resource::TagResourceError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::tag_resource::TagResourceError> for Error {
fn from(err: crate::operation::tag_resource::TagResourceError) -> Self {
match err {
crate::operation::tag_resource::TagResourceError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::tag_resource::TagResourceError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::tag_resource::TagResourceError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::tag_resource::TagResourceError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::tag_resource::TagResourceError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::tag_resource::TagResourceError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::untag_resource::UntagResourceError, R>> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::untag_resource::UntagResourceError, R>) -> Self {
match err {
::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
_ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
source: err.into(),
}),
}
}
}
impl From<crate::operation::untag_resource::UntagResourceError> for Error {
fn from(err: crate::operation::untag_resource::UntagResourceError) -> Self {
match err {
crate::operation::untag_resource::UntagResourceError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::untag_resource::UntagResourceError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::untag_resource::UntagResourceError::InternalFailureException(inner) => Error::InternalFailureException(inner),
crate::operation::untag_resource::UntagResourceError::LimitExceededException(inner) => Error::LimitExceededException(inner),
crate::operation::untag_resource::UntagResourceError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::untag_resource::UntagResourceError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl ::std::error::Error for Error {
fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
match self {
Error::AccessDeniedException(inner) => inner.source(),
Error::BadRequestException(inner) => inner.source(),
Error::ConflictException(inner) => inner.source(),
Error::InternalFailureException(inner) => inner.source(),
Error::LimitExceededException(inner) => inner.source(),
Error::NotFoundException(inner) => inner.source(),
Error::PreconditionFailedException(inner) => inner.source(),
Error::ResourceInUseException(inner) => inner.source(),
Error::Unhandled(inner) => ::std::option::Option::Some(&*inner.source),
}
}
}
impl ::aws_types::request_id::RequestId for Error {
fn request_id(&self) -> Option<&str> {
match self {
Self::AccessDeniedException(e) => e.request_id(),
Self::BadRequestException(e) => e.request_id(),
Self::ConflictException(e) => e.request_id(),
Self::InternalFailureException(e) => e.request_id(),
Self::LimitExceededException(e) => e.request_id(),
Self::NotFoundException(e) => e.request_id(),
Self::PreconditionFailedException(e) => e.request_id(),
Self::ResourceInUseException(e) => e.request_id(),
Self::Unhandled(e) => e.meta.request_id(),
}
}
}