#[non_exhaustive]
#[derive(std::fmt::Debug)]
pub enum Error {
InternalException(crate::types::error::InternalException),
InvalidRequestException(crate::types::error::InvalidRequestException),
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::InternalException(inner) => inner.fmt(f),
Error::InvalidRequestException(inner) => inner.fmt(f),
Error::Unhandled(inner) => inner.fmt(f),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::cancel_task_execution::CancelTaskExecutionError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::cancel_task_execution::CancelTaskExecutionError,
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::cancel_task_execution::CancelTaskExecutionError> for Error {
fn from(err: crate::operation::cancel_task_execution::CancelTaskExecutionError) -> Self {
match err {
crate::operation::cancel_task_execution::CancelTaskExecutionError::InternalException(inner) => Error::InternalException(inner),
crate::operation::cancel_task_execution::CancelTaskExecutionError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::cancel_task_execution::CancelTaskExecutionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::create_agent::CreateAgentError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::create_agent::CreateAgentError, 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_agent::CreateAgentError> for Error {
fn from(err: crate::operation::create_agent::CreateAgentError) -> Self {
match err {
crate::operation::create_agent::CreateAgentError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::create_agent::CreateAgentError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::create_agent::CreateAgentError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_efs::CreateLocationEfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_efs::CreateLocationEfsError,
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_location_efs::CreateLocationEfsError> for Error {
fn from(err: crate::operation::create_location_efs::CreateLocationEfsError) -> Self {
match err {
crate::operation::create_location_efs::CreateLocationEfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_efs::CreateLocationEfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_efs::CreateLocationEfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_lustre::CreateLocationFsxLustreError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_lustre::CreateLocationFsxLustreError,
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_location_fsx_lustre::CreateLocationFsxLustreError> for Error {
fn from(
err: crate::operation::create_location_fsx_lustre::CreateLocationFsxLustreError,
) -> Self {
match err {
crate::operation::create_location_fsx_lustre::CreateLocationFsxLustreError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_fsx_lustre::CreateLocationFsxLustreError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_fsx_lustre::CreateLocationFsxLustreError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_ontap::CreateLocationFsxOntapError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_ontap::CreateLocationFsxOntapError,
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_location_fsx_ontap::CreateLocationFsxOntapError> for Error {
fn from(err: crate::operation::create_location_fsx_ontap::CreateLocationFsxOntapError) -> Self {
match err {
crate::operation::create_location_fsx_ontap::CreateLocationFsxOntapError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_fsx_ontap::CreateLocationFsxOntapError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_fsx_ontap::CreateLocationFsxOntapError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_open_zfs::CreateLocationFsxOpenZfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_open_zfs::CreateLocationFsxOpenZfsError,
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_location_fsx_open_zfs::CreateLocationFsxOpenZfsError> for Error {
fn from(
err: crate::operation::create_location_fsx_open_zfs::CreateLocationFsxOpenZfsError,
) -> Self {
match err {
crate::operation::create_location_fsx_open_zfs::CreateLocationFsxOpenZfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_fsx_open_zfs::CreateLocationFsxOpenZfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_fsx_open_zfs::CreateLocationFsxOpenZfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_windows::CreateLocationFsxWindowsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_fsx_windows::CreateLocationFsxWindowsError,
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_location_fsx_windows::CreateLocationFsxWindowsError> for Error {
fn from(
err: crate::operation::create_location_fsx_windows::CreateLocationFsxWindowsError,
) -> Self {
match err {
crate::operation::create_location_fsx_windows::CreateLocationFsxWindowsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_fsx_windows::CreateLocationFsxWindowsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_fsx_windows::CreateLocationFsxWindowsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_hdfs::CreateLocationHdfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_hdfs::CreateLocationHdfsError,
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_location_hdfs::CreateLocationHdfsError> for Error {
fn from(err: crate::operation::create_location_hdfs::CreateLocationHdfsError) -> Self {
match err {
crate::operation::create_location_hdfs::CreateLocationHdfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_hdfs::CreateLocationHdfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_hdfs::CreateLocationHdfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_nfs::CreateLocationNfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_nfs::CreateLocationNfsError,
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_location_nfs::CreateLocationNfsError> for Error {
fn from(err: crate::operation::create_location_nfs::CreateLocationNfsError) -> Self {
match err {
crate::operation::create_location_nfs::CreateLocationNfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_nfs::CreateLocationNfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_nfs::CreateLocationNfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_object_storage::CreateLocationObjectStorageError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_object_storage::CreateLocationObjectStorageError,
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_location_object_storage::CreateLocationObjectStorageError>
for Error
{
fn from(
err: crate::operation::create_location_object_storage::CreateLocationObjectStorageError,
) -> Self {
match err {
crate::operation::create_location_object_storage::CreateLocationObjectStorageError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_object_storage::CreateLocationObjectStorageError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_object_storage::CreateLocationObjectStorageError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_s3::CreateLocationS3Error,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_s3::CreateLocationS3Error,
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_location_s3::CreateLocationS3Error> for Error {
fn from(err: crate::operation::create_location_s3::CreateLocationS3Error) -> Self {
match err {
crate::operation::create_location_s3::CreateLocationS3Error::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_s3::CreateLocationS3Error::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_s3::CreateLocationS3Error::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::create_location_smb::CreateLocationSmbError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::create_location_smb::CreateLocationSmbError,
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_location_smb::CreateLocationSmbError> for Error {
fn from(err: crate::operation::create_location_smb::CreateLocationSmbError) -> Self {
match err {
crate::operation::create_location_smb::CreateLocationSmbError::InternalException(inner) => Error::InternalException(inner),
crate::operation::create_location_smb::CreateLocationSmbError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::create_location_smb::CreateLocationSmbError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::create_task::CreateTaskError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::create_task::CreateTaskError, 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_task::CreateTaskError> for Error {
fn from(err: crate::operation::create_task::CreateTaskError) -> Self {
match err {
crate::operation::create_task::CreateTaskError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::create_task::CreateTaskError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::create_task::CreateTaskError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::delete_agent::DeleteAgentError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::delete_agent::DeleteAgentError, 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_agent::DeleteAgentError> for Error {
fn from(err: crate::operation::delete_agent::DeleteAgentError) -> Self {
match err {
crate::operation::delete_agent::DeleteAgentError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::delete_agent::DeleteAgentError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::delete_agent::DeleteAgentError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::delete_location::DeleteLocationError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::delete_location::DeleteLocationError,
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_location::DeleteLocationError> for Error {
fn from(err: crate::operation::delete_location::DeleteLocationError) -> Self {
match err {
crate::operation::delete_location::DeleteLocationError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::delete_location::DeleteLocationError::InvalidRequestException(
inner,
) => Error::InvalidRequestException(inner),
crate::operation::delete_location::DeleteLocationError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::delete_task::DeleteTaskError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::delete_task::DeleteTaskError, 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_task::DeleteTaskError> for Error {
fn from(err: crate::operation::delete_task::DeleteTaskError) -> Self {
match err {
crate::operation::delete_task::DeleteTaskError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::delete_task::DeleteTaskError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::delete_task::DeleteTaskError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<aws_smithy_http::result::SdkError<crate::operation::describe_agent::DescribeAgentError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_agent::DescribeAgentError,
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::describe_agent::DescribeAgentError> for Error {
fn from(err: crate::operation::describe_agent::DescribeAgentError) -> Self {
match err {
crate::operation::describe_agent::DescribeAgentError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::describe_agent::DescribeAgentError::InvalidRequestException(
inner,
) => Error::InvalidRequestException(inner),
crate::operation::describe_agent::DescribeAgentError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_efs::DescribeLocationEfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_efs::DescribeLocationEfsError,
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::describe_location_efs::DescribeLocationEfsError> for Error {
fn from(err: crate::operation::describe_location_efs::DescribeLocationEfsError) -> Self {
match err {
crate::operation::describe_location_efs::DescribeLocationEfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_efs::DescribeLocationEfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_efs::DescribeLocationEfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_lustre::DescribeLocationFsxLustreError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_lustre::DescribeLocationFsxLustreError,
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::describe_location_fsx_lustre::DescribeLocationFsxLustreError>
for Error
{
fn from(
err: crate::operation::describe_location_fsx_lustre::DescribeLocationFsxLustreError,
) -> Self {
match err {
crate::operation::describe_location_fsx_lustre::DescribeLocationFsxLustreError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_fsx_lustre::DescribeLocationFsxLustreError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_fsx_lustre::DescribeLocationFsxLustreError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_ontap::DescribeLocationFsxOntapError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_ontap::DescribeLocationFsxOntapError,
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::describe_location_fsx_ontap::DescribeLocationFsxOntapError> for Error {
fn from(
err: crate::operation::describe_location_fsx_ontap::DescribeLocationFsxOntapError,
) -> Self {
match err {
crate::operation::describe_location_fsx_ontap::DescribeLocationFsxOntapError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_fsx_ontap::DescribeLocationFsxOntapError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_fsx_ontap::DescribeLocationFsxOntapError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError,
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::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError>
for Error
{
fn from(
err: crate::operation::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError,
) -> Self {
match err {
crate::operation::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_fsx_open_zfs::DescribeLocationFsxOpenZfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_windows::DescribeLocationFsxWindowsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_fsx_windows::DescribeLocationFsxWindowsError,
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::describe_location_fsx_windows::DescribeLocationFsxWindowsError>
for Error
{
fn from(
err: crate::operation::describe_location_fsx_windows::DescribeLocationFsxWindowsError,
) -> Self {
match err {
crate::operation::describe_location_fsx_windows::DescribeLocationFsxWindowsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_fsx_windows::DescribeLocationFsxWindowsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_fsx_windows::DescribeLocationFsxWindowsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_hdfs::DescribeLocationHdfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_hdfs::DescribeLocationHdfsError,
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::describe_location_hdfs::DescribeLocationHdfsError> for Error {
fn from(err: crate::operation::describe_location_hdfs::DescribeLocationHdfsError) -> Self {
match err {
crate::operation::describe_location_hdfs::DescribeLocationHdfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_hdfs::DescribeLocationHdfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_hdfs::DescribeLocationHdfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_nfs::DescribeLocationNfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_nfs::DescribeLocationNfsError,
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::describe_location_nfs::DescribeLocationNfsError> for Error {
fn from(err: crate::operation::describe_location_nfs::DescribeLocationNfsError) -> Self {
match err {
crate::operation::describe_location_nfs::DescribeLocationNfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_nfs::DescribeLocationNfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_nfs::DescribeLocationNfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_object_storage::DescribeLocationObjectStorageError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_object_storage::DescribeLocationObjectStorageError,
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::describe_location_object_storage::DescribeLocationObjectStorageError>
for Error
{
fn from(
err: crate::operation::describe_location_object_storage::DescribeLocationObjectStorageError,
) -> Self {
match err {
crate::operation::describe_location_object_storage::DescribeLocationObjectStorageError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_object_storage::DescribeLocationObjectStorageError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_object_storage::DescribeLocationObjectStorageError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_s3::DescribeLocationS3Error,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_s3::DescribeLocationS3Error,
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::describe_location_s3::DescribeLocationS3Error> for Error {
fn from(err: crate::operation::describe_location_s3::DescribeLocationS3Error) -> Self {
match err {
crate::operation::describe_location_s3::DescribeLocationS3Error::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_s3::DescribeLocationS3Error::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_s3::DescribeLocationS3Error::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_location_smb::DescribeLocationSmbError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_location_smb::DescribeLocationSmbError,
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::describe_location_smb::DescribeLocationSmbError> for Error {
fn from(err: crate::operation::describe_location_smb::DescribeLocationSmbError) -> Self {
match err {
crate::operation::describe_location_smb::DescribeLocationSmbError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_location_smb::DescribeLocationSmbError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_location_smb::DescribeLocationSmbError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<aws_smithy_http::result::SdkError<crate::operation::describe_task::DescribeTaskError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_task::DescribeTaskError,
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::describe_task::DescribeTaskError> for Error {
fn from(err: crate::operation::describe_task::DescribeTaskError) -> Self {
match err {
crate::operation::describe_task::DescribeTaskError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::describe_task::DescribeTaskError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::describe_task::DescribeTaskError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::describe_task_execution::DescribeTaskExecutionError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::describe_task_execution::DescribeTaskExecutionError,
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::describe_task_execution::DescribeTaskExecutionError> for Error {
fn from(err: crate::operation::describe_task_execution::DescribeTaskExecutionError) -> Self {
match err {
crate::operation::describe_task_execution::DescribeTaskExecutionError::InternalException(inner) => Error::InternalException(inner),
crate::operation::describe_task_execution::DescribeTaskExecutionError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::describe_task_execution::DescribeTaskExecutionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::list_agents::ListAgentsError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::list_agents::ListAgentsError, 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::list_agents::ListAgentsError> for Error {
fn from(err: crate::operation::list_agents::ListAgentsError) -> Self {
match err {
crate::operation::list_agents::ListAgentsError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::list_agents::ListAgentsError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::list_agents::ListAgentsError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<aws_smithy_http::result::SdkError<crate::operation::list_locations::ListLocationsError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::list_locations::ListLocationsError,
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::list_locations::ListLocationsError> for Error {
fn from(err: crate::operation::list_locations::ListLocationsError) -> Self {
match err {
crate::operation::list_locations::ListLocationsError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::list_locations::ListLocationsError::InvalidRequestException(
inner,
) => Error::InvalidRequestException(inner),
crate::operation::list_locations::ListLocationsError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::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_http::result::SdkError<
crate::operation::list_tags_for_resource::ListTagsForResourceError,
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::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::InternalException(inner) => Error::InternalException(inner),
crate::operation::list_tags_for_resource::ListTagsForResourceError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::list_tags_for_resource::ListTagsForResourceError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::list_task_executions::ListTaskExecutionsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::list_task_executions::ListTaskExecutionsError,
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::list_task_executions::ListTaskExecutionsError> for Error {
fn from(err: crate::operation::list_task_executions::ListTaskExecutionsError) -> Self {
match err {
crate::operation::list_task_executions::ListTaskExecutionsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::list_task_executions::ListTaskExecutionsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::list_task_executions::ListTaskExecutionsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::list_tasks::ListTasksError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::list_tasks::ListTasksError, 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::list_tasks::ListTasksError> for Error {
fn from(err: crate::operation::list_tasks::ListTasksError) -> Self {
match err {
crate::operation::list_tasks::ListTasksError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::list_tasks::ListTasksError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::list_tasks::ListTasksError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::start_task_execution::StartTaskExecutionError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::start_task_execution::StartTaskExecutionError,
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::start_task_execution::StartTaskExecutionError> for Error {
fn from(err: crate::operation::start_task_execution::StartTaskExecutionError) -> Self {
match err {
crate::operation::start_task_execution::StartTaskExecutionError::InternalException(inner) => Error::InternalException(inner),
crate::operation::start_task_execution::StartTaskExecutionError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::start_task_execution::StartTaskExecutionError::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::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::tag_resource::TagResourceError::InvalidRequestException(inner) => {
Error::InvalidRequestException(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::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::untag_resource::UntagResourceError::InvalidRequestException(
inner,
) => Error::InvalidRequestException(inner),
crate::operation::untag_resource::UntagResourceError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::update_agent::UpdateAgentError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::update_agent::UpdateAgentError, 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_agent::UpdateAgentError> for Error {
fn from(err: crate::operation::update_agent::UpdateAgentError) -> Self {
match err {
crate::operation::update_agent::UpdateAgentError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::update_agent::UpdateAgentError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::update_agent::UpdateAgentError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::update_location_hdfs::UpdateLocationHdfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::update_location_hdfs::UpdateLocationHdfsError,
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_location_hdfs::UpdateLocationHdfsError> for Error {
fn from(err: crate::operation::update_location_hdfs::UpdateLocationHdfsError) -> Self {
match err {
crate::operation::update_location_hdfs::UpdateLocationHdfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::update_location_hdfs::UpdateLocationHdfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::update_location_hdfs::UpdateLocationHdfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::update_location_nfs::UpdateLocationNfsError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::update_location_nfs::UpdateLocationNfsError,
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_location_nfs::UpdateLocationNfsError> for Error {
fn from(err: crate::operation::update_location_nfs::UpdateLocationNfsError) -> Self {
match err {
crate::operation::update_location_nfs::UpdateLocationNfsError::InternalException(inner) => Error::InternalException(inner),
crate::operation::update_location_nfs::UpdateLocationNfsError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::update_location_nfs::UpdateLocationNfsError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::update_location_object_storage::UpdateLocationObjectStorageError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::update_location_object_storage::UpdateLocationObjectStorageError,
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_location_object_storage::UpdateLocationObjectStorageError>
for Error
{
fn from(
err: crate::operation::update_location_object_storage::UpdateLocationObjectStorageError,
) -> Self {
match err {
crate::operation::update_location_object_storage::UpdateLocationObjectStorageError::InternalException(inner) => Error::InternalException(inner),
crate::operation::update_location_object_storage::UpdateLocationObjectStorageError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::update_location_object_storage::UpdateLocationObjectStorageError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::update_location_smb::UpdateLocationSmbError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::update_location_smb::UpdateLocationSmbError,
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_location_smb::UpdateLocationSmbError> for Error {
fn from(err: crate::operation::update_location_smb::UpdateLocationSmbError) -> Self {
match err {
crate::operation::update_location_smb::UpdateLocationSmbError::InternalException(inner) => Error::InternalException(inner),
crate::operation::update_location_smb::UpdateLocationSmbError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::update_location_smb::UpdateLocationSmbError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl<R> From<aws_smithy_http::result::SdkError<crate::operation::update_task::UpdateTaskError, R>>
for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<crate::operation::update_task::UpdateTaskError, 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_task::UpdateTaskError> for Error {
fn from(err: crate::operation::update_task::UpdateTaskError) -> Self {
match err {
crate::operation::update_task::UpdateTaskError::InternalException(inner) => {
Error::InternalException(inner)
}
crate::operation::update_task::UpdateTaskError::InvalidRequestException(inner) => {
Error::InvalidRequestException(inner)
}
crate::operation::update_task::UpdateTaskError::Unhandled(inner) => {
Error::Unhandled(inner)
}
}
}
}
impl<R>
From<
aws_smithy_http::result::SdkError<
crate::operation::update_task_execution::UpdateTaskExecutionError,
R,
>,
> for Error
where
R: Send + Sync + std::fmt::Debug + 'static,
{
fn from(
err: aws_smithy_http::result::SdkError<
crate::operation::update_task_execution::UpdateTaskExecutionError,
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_task_execution::UpdateTaskExecutionError> for Error {
fn from(err: crate::operation::update_task_execution::UpdateTaskExecutionError) -> Self {
match err {
crate::operation::update_task_execution::UpdateTaskExecutionError::InternalException(inner) => Error::InternalException(inner),
crate::operation::update_task_execution::UpdateTaskExecutionError::InvalidRequestException(inner) => Error::InvalidRequestException(inner),
crate::operation::update_task_execution::UpdateTaskExecutionError::Unhandled(inner) => Error::Unhandled(inner),
}
}
}
impl std::error::Error for Error {}
impl aws_http::request_id::RequestId for Error {
fn request_id(&self) -> Option<&str> {
match self {
Self::InternalException(e) => e.request_id(),
Self::InvalidRequestException(e) => e.request_id(),
Self::Unhandled(e) => e.request_id(),
}
}
}