#[non_exhaustive]
#[derive(::std::fmt::Debug)]
pub enum Error {
#[allow(missing_docs)] AccessDeniedException(crate::types::error::AccessDeniedException),
BadRequestException(crate::types::error::BadRequestException),
ConflictException(crate::types::error::ConflictException),
NotFoundException(crate::types::error::NotFoundException),
TooManyRequestsException(crate::types::error::TooManyRequestsException),
Unhandled(::aws_smithy_types::error::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::NotFoundException(inner) => inner.fmt(f),
Error::TooManyRequestsException(inner) => inner.fmt(f),
Error::Unhandled(inner) => inner.fmt(f),
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::create_api::CreateApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::create_api::CreateApiError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_api::CreateApiError> for Error {
fn from(err: crate::operation::create_api::CreateApiError) -> Self {
match err {
crate::operation::create_api::CreateApiError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::create_api::CreateApiError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::create_api::CreateApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::create_api::CreateApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::create_api::CreateApiError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_api_mapping::CreateApiMappingError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_api_mapping::CreateApiMappingError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_api_mapping::CreateApiMappingError> for Error {
fn from(err: crate::operation::create_api_mapping::CreateApiMappingError) -> Self {
match err {
crate::operation::create_api_mapping::CreateApiMappingError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_api_mapping::CreateApiMappingError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_api_mapping::CreateApiMappingError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_api_mapping::CreateApiMappingError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_api_mapping::CreateApiMappingError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_authorizer::CreateAuthorizerError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_authorizer::CreateAuthorizerError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_authorizer::CreateAuthorizerError> for Error {
fn from(err: crate::operation::create_authorizer::CreateAuthorizerError) -> Self {
match err {
crate::operation::create_authorizer::CreateAuthorizerError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_authorizer::CreateAuthorizerError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_authorizer::CreateAuthorizerError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_authorizer::CreateAuthorizerError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_authorizer::CreateAuthorizerError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_deployment::CreateDeploymentError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_deployment::CreateDeploymentError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_deployment::CreateDeploymentError> for Error {
fn from(err: crate::operation::create_deployment::CreateDeploymentError) -> Self {
match err {
crate::operation::create_deployment::CreateDeploymentError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_deployment::CreateDeploymentError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_deployment::CreateDeploymentError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_deployment::CreateDeploymentError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_deployment::CreateDeploymentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_domain_name::CreateDomainNameError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_domain_name::CreateDomainNameError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_domain_name::CreateDomainNameError> for Error {
fn from(err: crate::operation::create_domain_name::CreateDomainNameError) -> Self {
match err {
crate::operation::create_domain_name::CreateDomainNameError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
crate::operation::create_domain_name::CreateDomainNameError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_domain_name::CreateDomainNameError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_domain_name::CreateDomainNameError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_domain_name::CreateDomainNameError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_domain_name::CreateDomainNameError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_integration::CreateIntegrationError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_integration::CreateIntegrationError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_integration::CreateIntegrationError> for Error {
fn from(err: crate::operation::create_integration::CreateIntegrationError) -> Self {
match err {
crate::operation::create_integration::CreateIntegrationError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_integration::CreateIntegrationError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_integration::CreateIntegrationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_integration::CreateIntegrationError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_integration::CreateIntegrationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_integration_response::CreateIntegrationResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_integration_response::CreateIntegrationResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_integration_response::CreateIntegrationResponseError> for Error {
fn from(
err: crate::operation::create_integration_response::CreateIntegrationResponseError,
) -> Self {
match err {
crate::operation::create_integration_response::CreateIntegrationResponseError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_integration_response::CreateIntegrationResponseError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_integration_response::CreateIntegrationResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_integration_response::CreateIntegrationResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_integration_response::CreateIntegrationResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::create_model::CreateModelError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_model::CreateModelError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_model::CreateModelError> for Error {
fn from(err: crate::operation::create_model::CreateModelError) -> Self {
match err {
crate::operation::create_model::CreateModelError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::create_model::CreateModelError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::create_model::CreateModelError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::create_model::CreateModelError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::create_model::CreateModelError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::create_route::CreateRouteError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_route::CreateRouteError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_route::CreateRouteError> for Error {
fn from(err: crate::operation::create_route::CreateRouteError) -> Self {
match err {
crate::operation::create_route::CreateRouteError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::create_route::CreateRouteError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::create_route::CreateRouteError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::create_route::CreateRouteError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::create_route::CreateRouteError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_route_response::CreateRouteResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_route_response::CreateRouteResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_route_response::CreateRouteResponseError> for Error {
fn from(err: crate::operation::create_route_response::CreateRouteResponseError) -> Self {
match err {
crate::operation::create_route_response::CreateRouteResponseError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::create_route_response::CreateRouteResponseError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::create_route_response::CreateRouteResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::create_route_response::CreateRouteResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::create_route_response::CreateRouteResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::create_stage::CreateStageError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_stage::CreateStageError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_stage::CreateStageError> for Error {
fn from(err: crate::operation::create_stage::CreateStageError) -> Self {
match err {
crate::operation::create_stage::CreateStageError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::create_stage::CreateStageError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::create_stage::CreateStageError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::create_stage::CreateStageError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::create_stage::CreateStageError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::create_vpc_link::CreateVpcLinkError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::create_vpc_link::CreateVpcLinkError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::create_vpc_link::CreateVpcLinkError> for Error {
fn from(err: crate::operation::create_vpc_link::CreateVpcLinkError) -> Self {
match err {
crate::operation::create_vpc_link::CreateVpcLinkError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::create_vpc_link::CreateVpcLinkError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::create_vpc_link::CreateVpcLinkError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError> for Error {
fn from(
err: crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError,
) -> Self {
match err {
crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_access_log_settings::DeleteAccessLogSettingsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::delete_api::DeleteApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::delete_api::DeleteApiError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_api::DeleteApiError> for Error {
fn from(err: crate::operation::delete_api::DeleteApiError) -> Self {
match err {
crate::operation::delete_api::DeleteApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::delete_api::DeleteApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::delete_api::DeleteApiError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_api_mapping::DeleteApiMappingError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_api_mapping::DeleteApiMappingError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_api_mapping::DeleteApiMappingError> for Error {
fn from(err: crate::operation::delete_api_mapping::DeleteApiMappingError) -> Self {
match err {
crate::operation::delete_api_mapping::DeleteApiMappingError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::delete_api_mapping::DeleteApiMappingError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_api_mapping::DeleteApiMappingError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_api_mapping::DeleteApiMappingError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_authorizer::DeleteAuthorizerError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_authorizer::DeleteAuthorizerError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_authorizer::DeleteAuthorizerError> for Error {
fn from(err: crate::operation::delete_authorizer::DeleteAuthorizerError) -> Self {
match err {
crate::operation::delete_authorizer::DeleteAuthorizerError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_authorizer::DeleteAuthorizerError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_authorizer::DeleteAuthorizerError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_cors_configuration::DeleteCorsConfigurationError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_cors_configuration::DeleteCorsConfigurationError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_cors_configuration::DeleteCorsConfigurationError> for Error {
fn from(
err: crate::operation::delete_cors_configuration::DeleteCorsConfigurationError,
) -> Self {
match err {
crate::operation::delete_cors_configuration::DeleteCorsConfigurationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_cors_configuration::DeleteCorsConfigurationError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_cors_configuration::DeleteCorsConfigurationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_deployment::DeleteDeploymentError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_deployment::DeleteDeploymentError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_deployment::DeleteDeploymentError> for Error {
fn from(err: crate::operation::delete_deployment::DeleteDeploymentError) -> Self {
match err {
crate::operation::delete_deployment::DeleteDeploymentError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_deployment::DeleteDeploymentError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_deployment::DeleteDeploymentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_domain_name::DeleteDomainNameError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_domain_name::DeleteDomainNameError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_domain_name::DeleteDomainNameError> for Error {
fn from(err: crate::operation::delete_domain_name::DeleteDomainNameError) -> Self {
match err {
crate::operation::delete_domain_name::DeleteDomainNameError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_domain_name::DeleteDomainNameError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_domain_name::DeleteDomainNameError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_integration::DeleteIntegrationError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_integration::DeleteIntegrationError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_integration::DeleteIntegrationError> for Error {
fn from(err: crate::operation::delete_integration::DeleteIntegrationError) -> Self {
match err {
crate::operation::delete_integration::DeleteIntegrationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_integration::DeleteIntegrationError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_integration::DeleteIntegrationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_integration_response::DeleteIntegrationResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_integration_response::DeleteIntegrationResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_integration_response::DeleteIntegrationResponseError> for Error {
fn from(
err: crate::operation::delete_integration_response::DeleteIntegrationResponseError,
) -> Self {
match err {
crate::operation::delete_integration_response::DeleteIntegrationResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_integration_response::DeleteIntegrationResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_integration_response::DeleteIntegrationResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::delete_model::DeleteModelError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_model::DeleteModelError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_model::DeleteModelError> for Error {
fn from(err: crate::operation::delete_model::DeleteModelError) -> Self {
match err {
crate::operation::delete_model::DeleteModelError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::delete_model::DeleteModelError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::delete_model::DeleteModelError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::delete_route::DeleteRouteError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_route::DeleteRouteError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_route::DeleteRouteError> for Error {
fn from(err: crate::operation::delete_route::DeleteRouteError) -> Self {
match err {
crate::operation::delete_route::DeleteRouteError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::delete_route::DeleteRouteError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::delete_route::DeleteRouteError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError>
for Error
{
fn from(
err: crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError,
) -> Self {
match err {
crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_route_request_parameter::DeleteRouteRequestParameterError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_route_response::DeleteRouteResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_route_response::DeleteRouteResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_route_response::DeleteRouteResponseError> for Error {
fn from(err: crate::operation::delete_route_response::DeleteRouteResponseError) -> Self {
match err {
crate::operation::delete_route_response::DeleteRouteResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_route_response::DeleteRouteResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_route_response::DeleteRouteResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_route_settings::DeleteRouteSettingsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_route_settings::DeleteRouteSettingsError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_route_settings::DeleteRouteSettingsError> for Error {
fn from(err: crate::operation::delete_route_settings::DeleteRouteSettingsError) -> Self {
match err {
crate::operation::delete_route_settings::DeleteRouteSettingsError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::delete_route_settings::DeleteRouteSettingsError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::delete_route_settings::DeleteRouteSettingsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::delete_stage::DeleteStageError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_stage::DeleteStageError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_stage::DeleteStageError> for Error {
fn from(err: crate::operation::delete_stage::DeleteStageError) -> Self {
match err {
crate::operation::delete_stage::DeleteStageError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::delete_stage::DeleteStageError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::delete_stage::DeleteStageError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::delete_vpc_link::DeleteVpcLinkError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::delete_vpc_link::DeleteVpcLinkError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::delete_vpc_link::DeleteVpcLinkError> for Error {
fn from(err: crate::operation::delete_vpc_link::DeleteVpcLinkError) -> Self {
match err {
crate::operation::delete_vpc_link::DeleteVpcLinkError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::delete_vpc_link::DeleteVpcLinkError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::delete_vpc_link::DeleteVpcLinkError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::export_api::ExportApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::export_api::ExportApiError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::export_api::ExportApiError> for Error {
fn from(err: crate::operation::export_api::ExportApiError) -> Self {
match err {
crate::operation::export_api::ExportApiError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::export_api::ExportApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::export_api::ExportApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::export_api::ExportApiError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_api::GetApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_api::GetApiError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_api::GetApiError> for Error {
fn from(err: crate::operation::get_api::GetApiError) -> Self {
match err {
crate::operation::get_api::GetApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_api::GetApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_api::GetApiError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_api_mapping::GetApiMappingError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_api_mapping::GetApiMappingError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_api_mapping::GetApiMappingError> for Error {
fn from(err: crate::operation::get_api_mapping::GetApiMappingError) -> Self {
match err {
crate::operation::get_api_mapping::GetApiMappingError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_api_mapping::GetApiMappingError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_api_mapping::GetApiMappingError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_api_mapping::GetApiMappingError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_api_mappings::GetApiMappingsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_api_mappings::GetApiMappingsError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_api_mappings::GetApiMappingsError> for Error {
fn from(err: crate::operation::get_api_mappings::GetApiMappingsError) -> Self {
match err {
crate::operation::get_api_mappings::GetApiMappingsError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_api_mappings::GetApiMappingsError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_api_mappings::GetApiMappingsError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_api_mappings::GetApiMappingsError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_apis::GetApisError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_apis::GetApisError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_apis::GetApisError> for Error {
fn from(err: crate::operation::get_apis::GetApisError) -> Self {
match err {
crate::operation::get_apis::GetApisError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_apis::GetApisError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_apis::GetApisError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_apis::GetApisError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_authorizer::GetAuthorizerError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_authorizer::GetAuthorizerError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_authorizer::GetAuthorizerError> for Error {
fn from(err: crate::operation::get_authorizer::GetAuthorizerError) -> Self {
match err {
crate::operation::get_authorizer::GetAuthorizerError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_authorizer::GetAuthorizerError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_authorizer::GetAuthorizerError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_authorizers::GetAuthorizersError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_authorizers::GetAuthorizersError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_authorizers::GetAuthorizersError> for Error {
fn from(err: crate::operation::get_authorizers::GetAuthorizersError) -> Self {
match err {
crate::operation::get_authorizers::GetAuthorizersError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_authorizers::GetAuthorizersError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_authorizers::GetAuthorizersError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_authorizers::GetAuthorizersError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_deployment::GetDeploymentError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_deployment::GetDeploymentError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_deployment::GetDeploymentError> for Error {
fn from(err: crate::operation::get_deployment::GetDeploymentError) -> Self {
match err {
crate::operation::get_deployment::GetDeploymentError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_deployment::GetDeploymentError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_deployment::GetDeploymentError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_deployments::GetDeploymentsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_deployments::GetDeploymentsError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_deployments::GetDeploymentsError> for Error {
fn from(err: crate::operation::get_deployments::GetDeploymentsError) -> Self {
match err {
crate::operation::get_deployments::GetDeploymentsError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_deployments::GetDeploymentsError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_deployments::GetDeploymentsError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_deployments::GetDeploymentsError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_domain_name::GetDomainNameError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_domain_name::GetDomainNameError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_domain_name::GetDomainNameError> for Error {
fn from(err: crate::operation::get_domain_name::GetDomainNameError) -> Self {
match err {
crate::operation::get_domain_name::GetDomainNameError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_domain_name::GetDomainNameError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_domain_name::GetDomainNameError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_domain_names::GetDomainNamesError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_domain_names::GetDomainNamesError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_domain_names::GetDomainNamesError> for Error {
fn from(err: crate::operation::get_domain_names::GetDomainNamesError) -> Self {
match err {
crate::operation::get_domain_names::GetDomainNamesError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_domain_names::GetDomainNamesError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_domain_names::GetDomainNamesError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_domain_names::GetDomainNamesError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_integration::GetIntegrationError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_integration::GetIntegrationError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_integration::GetIntegrationError> for Error {
fn from(err: crate::operation::get_integration::GetIntegrationError) -> Self {
match err {
crate::operation::get_integration::GetIntegrationError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_integration::GetIntegrationError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_integration::GetIntegrationError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_integration_response::GetIntegrationResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_integration_response::GetIntegrationResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_integration_response::GetIntegrationResponseError> for Error {
fn from(err: crate::operation::get_integration_response::GetIntegrationResponseError) -> Self {
match err {
crate::operation::get_integration_response::GetIntegrationResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_integration_response::GetIntegrationResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::get_integration_response::GetIntegrationResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_integration_responses::GetIntegrationResponsesError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_integration_responses::GetIntegrationResponsesError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_integration_responses::GetIntegrationResponsesError> for Error {
fn from(
err: crate::operation::get_integration_responses::GetIntegrationResponsesError,
) -> Self {
match err {
crate::operation::get_integration_responses::GetIntegrationResponsesError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_integration_responses::GetIntegrationResponsesError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_integration_responses::GetIntegrationResponsesError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::get_integration_responses::GetIntegrationResponsesError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_integrations::GetIntegrationsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_integrations::GetIntegrationsError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_integrations::GetIntegrationsError> for Error {
fn from(err: crate::operation::get_integrations::GetIntegrationsError) -> Self {
match err {
crate::operation::get_integrations::GetIntegrationsError::BadRequestException(
inner,
) => Error::BadRequestException(inner),
crate::operation::get_integrations::GetIntegrationsError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_integrations::GetIntegrationsError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::get_integrations::GetIntegrationsError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_model::GetModelError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_model::GetModelError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_model::GetModelError> for Error {
fn from(err: crate::operation::get_model::GetModelError) -> Self {
match err {
crate::operation::get_model::GetModelError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_model::GetModelError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_model::GetModelError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_models::GetModelsError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_models::GetModelsError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_models::GetModelsError> for Error {
fn from(err: crate::operation::get_models::GetModelsError) -> Self {
match err {
crate::operation::get_models::GetModelsError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_models::GetModelsError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_models::GetModelsError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_models::GetModelsError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_model_template::GetModelTemplateError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_model_template::GetModelTemplateError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_model_template::GetModelTemplateError> for Error {
fn from(err: crate::operation::get_model_template::GetModelTemplateError) -> Self {
match err {
crate::operation::get_model_template::GetModelTemplateError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_model_template::GetModelTemplateError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::get_model_template::GetModelTemplateError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_route::GetRouteError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_route::GetRouteError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_route::GetRouteError> for Error {
fn from(err: crate::operation::get_route::GetRouteError) -> Self {
match err {
crate::operation::get_route::GetRouteError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_route::GetRouteError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_route::GetRouteError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_route_response::GetRouteResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_route_response::GetRouteResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_route_response::GetRouteResponseError> for Error {
fn from(err: crate::operation::get_route_response::GetRouteResponseError) -> Self {
match err {
crate::operation::get_route_response::GetRouteResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_route_response::GetRouteResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::get_route_response::GetRouteResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::get_route_responses::GetRouteResponsesError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_route_responses::GetRouteResponsesError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_route_responses::GetRouteResponsesError> for Error {
fn from(err: crate::operation::get_route_responses::GetRouteResponsesError) -> Self {
match err {
crate::operation::get_route_responses::GetRouteResponsesError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::get_route_responses::GetRouteResponsesError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::get_route_responses::GetRouteResponsesError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::get_route_responses::GetRouteResponsesError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_routes::GetRoutesError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_routes::GetRoutesError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_routes::GetRoutesError> for Error {
fn from(err: crate::operation::get_routes::GetRoutesError) -> Self {
match err {
crate::operation::get_routes::GetRoutesError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_routes::GetRoutesError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_routes::GetRoutesError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_routes::GetRoutesError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_stage::GetStageError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_stage::GetStageError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_stage::GetStageError> for Error {
fn from(err: crate::operation::get_stage::GetStageError) -> Self {
match err {
crate::operation::get_stage::GetStageError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_stage::GetStageError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_stage::GetStageError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_stages::GetStagesError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_stages::GetStagesError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_stages::GetStagesError> for Error {
fn from(err: crate::operation::get_stages::GetStagesError) -> Self {
match err {
crate::operation::get_stages::GetStagesError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_stages::GetStagesError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_stages::GetStagesError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_stages::GetStagesError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::get_tags::GetTagsError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::get_tags::GetTagsError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_tags::GetTagsError> for Error {
fn from(err: crate::operation::get_tags::GetTagsError) -> Self {
match err {
crate::operation::get_tags::GetTagsError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_tags::GetTagsError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::get_tags::GetTagsError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_tags::GetTagsError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_tags::GetTagsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::get_vpc_link::GetVpcLinkError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_vpc_link::GetVpcLinkError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_vpc_link::GetVpcLinkError> for Error {
fn from(err: crate::operation::get_vpc_link::GetVpcLinkError) -> Self {
match err {
crate::operation::get_vpc_link::GetVpcLinkError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::get_vpc_link::GetVpcLinkError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_vpc_link::GetVpcLinkError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::get_vpc_links::GetVpcLinksError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::get_vpc_links::GetVpcLinksError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::get_vpc_links::GetVpcLinksError> for Error {
fn from(err: crate::operation::get_vpc_links::GetVpcLinksError) -> Self {
match err {
crate::operation::get_vpc_links::GetVpcLinksError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::get_vpc_links::GetVpcLinksError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::get_vpc_links::GetVpcLinksError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::import_api::ImportApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::import_api::ImportApiError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::import_api::ImportApiError> for Error {
fn from(err: crate::operation::import_api::ImportApiError) -> Self {
match err {
crate::operation::import_api::ImportApiError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::import_api::ImportApiError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::import_api::ImportApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::import_api::ImportApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::import_api::ImportApiError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::reimport_api::ReimportApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::reimport_api::ReimportApiError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::reimport_api::ReimportApiError> for Error {
fn from(err: crate::operation::reimport_api::ReimportApiError) -> Self {
match err {
crate::operation::reimport_api::ReimportApiError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::reimport_api::ReimportApiError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::reimport_api::ReimportApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::reimport_api::ReimportApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::reimport_api::ReimportApiError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError> for Error {
fn from(err: crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError) -> Self {
match err {
crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::reset_authorizers_cache::ResetAuthorizersCacheError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::tag_resource::TagResourceError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::tag_resource::TagResourceError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
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::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::tag_resource::TagResourceError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::tag_resource::TagResourceError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::untag_resource::UntagResourceError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::untag_resource::UntagResourceError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
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::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::untag_resource::UntagResourceError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::untag_resource::UntagResourceError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<::aws_smithy_http::result::SdkError<crate::operation::update_api::UpdateApiError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<crate::operation::update_api::UpdateApiError, R>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_api::UpdateApiError> for Error {
fn from(err: crate::operation::update_api::UpdateApiError) -> Self {
match err {
crate::operation::update_api::UpdateApiError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::update_api::UpdateApiError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::update_api::UpdateApiError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::update_api::UpdateApiError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::update_api::UpdateApiError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_api_mapping::UpdateApiMappingError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_api_mapping::UpdateApiMappingError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_api_mapping::UpdateApiMappingError> for Error {
fn from(err: crate::operation::update_api_mapping::UpdateApiMappingError) -> Self {
match err {
crate::operation::update_api_mapping::UpdateApiMappingError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_api_mapping::UpdateApiMappingError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_api_mapping::UpdateApiMappingError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_api_mapping::UpdateApiMappingError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_api_mapping::UpdateApiMappingError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_authorizer::UpdateAuthorizerError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_authorizer::UpdateAuthorizerError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_authorizer::UpdateAuthorizerError> for Error {
fn from(err: crate::operation::update_authorizer::UpdateAuthorizerError) -> Self {
match err {
crate::operation::update_authorizer::UpdateAuthorizerError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_authorizer::UpdateAuthorizerError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_authorizer::UpdateAuthorizerError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_authorizer::UpdateAuthorizerError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_authorizer::UpdateAuthorizerError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_deployment::UpdateDeploymentError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_deployment::UpdateDeploymentError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_deployment::UpdateDeploymentError> for Error {
fn from(err: crate::operation::update_deployment::UpdateDeploymentError) -> Self {
match err {
crate::operation::update_deployment::UpdateDeploymentError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_deployment::UpdateDeploymentError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_deployment::UpdateDeploymentError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_deployment::UpdateDeploymentError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_deployment::UpdateDeploymentError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_domain_name::UpdateDomainNameError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_domain_name::UpdateDomainNameError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_domain_name::UpdateDomainNameError> for Error {
fn from(err: crate::operation::update_domain_name::UpdateDomainNameError) -> Self {
match err {
crate::operation::update_domain_name::UpdateDomainNameError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_domain_name::UpdateDomainNameError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_domain_name::UpdateDomainNameError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_domain_name::UpdateDomainNameError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_domain_name::UpdateDomainNameError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_integration::UpdateIntegrationError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_integration::UpdateIntegrationError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_integration::UpdateIntegrationError> for Error {
fn from(err: crate::operation::update_integration::UpdateIntegrationError) -> Self {
match err {
crate::operation::update_integration::UpdateIntegrationError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_integration::UpdateIntegrationError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_integration::UpdateIntegrationError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_integration::UpdateIntegrationError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_integration::UpdateIntegrationError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_integration_response::UpdateIntegrationResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_integration_response::UpdateIntegrationResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_integration_response::UpdateIntegrationResponseError> for Error {
fn from(
err: crate::operation::update_integration_response::UpdateIntegrationResponseError,
) -> Self {
match err {
crate::operation::update_integration_response::UpdateIntegrationResponseError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_integration_response::UpdateIntegrationResponseError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_integration_response::UpdateIntegrationResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_integration_response::UpdateIntegrationResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_integration_response::UpdateIntegrationResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::update_model::UpdateModelError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_model::UpdateModelError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_model::UpdateModelError> for Error {
fn from(err: crate::operation::update_model::UpdateModelError) -> Self {
match err {
crate::operation::update_model::UpdateModelError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::update_model::UpdateModelError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::update_model::UpdateModelError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::update_model::UpdateModelError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::update_model::UpdateModelError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::update_route::UpdateRouteError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_route::UpdateRouteError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_route::UpdateRouteError> for Error {
fn from(err: crate::operation::update_route::UpdateRouteError) -> Self {
match err {
crate::operation::update_route::UpdateRouteError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::update_route::UpdateRouteError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::update_route::UpdateRouteError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::update_route::UpdateRouteError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::update_route::UpdateRouteError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_route_response::UpdateRouteResponseError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_route_response::UpdateRouteResponseError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_route_response::UpdateRouteResponseError> for Error {
fn from(err: crate::operation::update_route_response::UpdateRouteResponseError) -> Self {
match err {
crate::operation::update_route_response::UpdateRouteResponseError::BadRequestException(inner) => Error::BadRequestException(inner),
crate::operation::update_route_response::UpdateRouteResponseError::ConflictException(inner) => Error::ConflictException(inner),
crate::operation::update_route_response::UpdateRouteResponseError::NotFoundException(inner) => Error::NotFoundException(inner),
crate::operation::update_route_response::UpdateRouteResponseError::TooManyRequestsException(inner) => Error::TooManyRequestsException(inner),
crate::operation::update_route_response::UpdateRouteResponseError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<::aws_smithy_http::result::SdkError<crate::operation::update_stage::UpdateStageError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_stage::UpdateStageError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_stage::UpdateStageError> for Error {
fn from(err: crate::operation::update_stage::UpdateStageError) -> Self {
match err {
crate::operation::update_stage::UpdateStageError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::update_stage::UpdateStageError::ConflictException(inner) => {
Error::ConflictException(inner)
}
crate::operation::update_stage::UpdateStageError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::update_stage::UpdateStageError::TooManyRequestsException(inner) => {
Error::TooManyRequestsException(inner)
}
crate::operation::update_stage::UpdateStageError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
::aws_smithy_http::result::SdkError<
crate::operation::update_vpc_link::UpdateVpcLinkError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: ::aws_smithy_http::result::SdkError<
crate::operation::update_vpc_link::UpdateVpcLinkError,
R,
>,
) -> Self {
match err {
::aws_smithy_http::result::SdkError::ServiceError(context) => {
Self::from(context.into_err())
}
_ => Error::Unhandled(
::aws_smithy_types::error::Unhandled::builder()
.meta(
::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err)
.clone(),
)
.source(err)
.build(),
),
}
}
}
impl From<crate::operation::update_vpc_link::UpdateVpcLinkError> for Error {
fn from(err: crate::operation::update_vpc_link::UpdateVpcLinkError) -> Self {
match err {
crate::operation::update_vpc_link::UpdateVpcLinkError::BadRequestException(inner) => {
Error::BadRequestException(inner)
}
crate::operation::update_vpc_link::UpdateVpcLinkError::NotFoundException(inner) => {
Error::NotFoundException(inner)
}
crate::operation::update_vpc_link::UpdateVpcLinkError::TooManyRequestsException(
inner,
) => Error::TooManyRequestsException(inner),
crate::operation::update_vpc_link::UpdateVpcLinkError::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::NotFoundException(inner) => inner.source(),
Error::TooManyRequestsException(inner) => inner.source(),
Error::Unhandled(inner) => inner.source(),
}
}
}
impl ::aws_http::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::NotFoundException(e) => e.request_id(),
Self::TooManyRequestsException(e) => e.request_id(),
Self::Unhandled(e) => e.request_id(),
}
}
}