aws_sdk_billing/
error_meta.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2/// All possible error types for this service.
3#[non_exhaustive]
4#[derive(::std::fmt::Debug)]
5pub enum Error {
6    /// <p>You don't have sufficient access to perform this action.</p>
7    AccessDeniedException(crate::types::error::AccessDeniedException),
8    /// <p>Exception thrown when a billing view's health status prevents an operation from being performed. This may occur if the billing view is in a state other than <code>HEALTHY</code>.</p>
9    BillingViewHealthStatusException(crate::types::error::BillingViewHealthStatusException),
10    /// <p>The requested operation would cause a conflict with the current state of a service resource associated with the request. Resolve the conflict before retrying this request.</p>
11    ConflictException(crate::types::error::ConflictException),
12    /// <p>The request processing failed because of an unknown error, exception, or failure.</p>
13    InternalServerException(crate::types::error::InternalServerException),
14    /// <p>The specified ARN in the request doesn't exist.</p>
15    ResourceNotFoundException(crate::types::error::ResourceNotFoundException),
16    /// <p>You've reached the limit of resources you can create, or exceeded the size of an individual resource.</p>
17    ServiceQuotaExceededException(crate::types::error::ServiceQuotaExceededException),
18    /// <p>The request was denied due to request throttling.</p>
19    ThrottlingException(crate::types::error::ThrottlingException),
20    /// <p>The input fails to satisfy the constraints specified by an Amazon Web Services service.</p>
21    ValidationException(crate::types::error::ValidationException),
22    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
23    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
24    variable wildcard pattern and check `.code()`:
25     \
26    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
27     \
28    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-Error) for what information is available for the error.")]
29    Unhandled(crate::error::sealed_unhandled::Unhandled),
30}
31impl ::std::fmt::Display for Error {
32    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
33        match self {
34            Error::AccessDeniedException(inner) => inner.fmt(f),
35            Error::BillingViewHealthStatusException(inner) => inner.fmt(f),
36            Error::ConflictException(inner) => inner.fmt(f),
37            Error::InternalServerException(inner) => inner.fmt(f),
38            Error::ResourceNotFoundException(inner) => inner.fmt(f),
39            Error::ServiceQuotaExceededException(inner) => inner.fmt(f),
40            Error::ThrottlingException(inner) => inner.fmt(f),
41            Error::ValidationException(inner) => inner.fmt(f),
42            Error::Unhandled(_) => {
43                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
44                    write!(f, "unhandled error ({code})")
45                } else {
46                    f.write_str("unhandled error")
47                }
48            }
49        }
50    }
51}
52impl From<::aws_smithy_types::error::operation::BuildError> for Error {
53    fn from(value: ::aws_smithy_types::error::operation::BuildError) -> Self {
54        Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
55            source: value.into(),
56            meta: ::std::default::Default::default(),
57        })
58    }
59}
60impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for Error {
61    fn meta(&self) -> &::aws_smithy_types::error::metadata::ErrorMetadata {
62        match self {
63            Self::AccessDeniedException(inner) => inner.meta(),
64            Self::BillingViewHealthStatusException(inner) => inner.meta(),
65            Self::ConflictException(inner) => inner.meta(),
66            Self::InternalServerException(inner) => inner.meta(),
67            Self::ResourceNotFoundException(inner) => inner.meta(),
68            Self::ServiceQuotaExceededException(inner) => inner.meta(),
69            Self::ThrottlingException(inner) => inner.meta(),
70            Self::ValidationException(inner) => inner.meta(),
71            Self::Unhandled(inner) => &inner.meta,
72        }
73    }
74}
75impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::associate_source_views::AssociateSourceViewsError, R>> for Error
76where
77    R: Send + Sync + std::fmt::Debug + 'static,
78{
79    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::associate_source_views::AssociateSourceViewsError, R>) -> Self {
80        match err {
81            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
82            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
83                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
84                source: err.into(),
85            }),
86        }
87    }
88}
89impl From<crate::operation::associate_source_views::AssociateSourceViewsError> for Error {
90    fn from(err: crate::operation::associate_source_views::AssociateSourceViewsError) -> Self {
91        match err {
92            crate::operation::associate_source_views::AssociateSourceViewsError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
93            crate::operation::associate_source_views::AssociateSourceViewsError::BillingViewHealthStatusException(inner) => {
94                Error::BillingViewHealthStatusException(inner)
95            }
96            crate::operation::associate_source_views::AssociateSourceViewsError::ConflictException(inner) => Error::ConflictException(inner),
97            crate::operation::associate_source_views::AssociateSourceViewsError::InternalServerException(inner) => {
98                Error::InternalServerException(inner)
99            }
100            crate::operation::associate_source_views::AssociateSourceViewsError::ResourceNotFoundException(inner) => {
101                Error::ResourceNotFoundException(inner)
102            }
103            crate::operation::associate_source_views::AssociateSourceViewsError::ServiceQuotaExceededException(inner) => {
104                Error::ServiceQuotaExceededException(inner)
105            }
106            crate::operation::associate_source_views::AssociateSourceViewsError::ThrottlingException(inner) => Error::ThrottlingException(inner),
107            crate::operation::associate_source_views::AssociateSourceViewsError::ValidationException(inner) => Error::ValidationException(inner),
108            crate::operation::associate_source_views::AssociateSourceViewsError::Unhandled(inner) => Error::Unhandled(inner),
109        }
110    }
111}
112impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_billing_view::CreateBillingViewError, R>> for Error
113where
114    R: Send + Sync + std::fmt::Debug + 'static,
115{
116    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_billing_view::CreateBillingViewError, R>) -> Self {
117        match err {
118            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
119            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
120                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
121                source: err.into(),
122            }),
123        }
124    }
125}
126impl From<crate::operation::create_billing_view::CreateBillingViewError> for Error {
127    fn from(err: crate::operation::create_billing_view::CreateBillingViewError) -> Self {
128        match err {
129            crate::operation::create_billing_view::CreateBillingViewError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
130            crate::operation::create_billing_view::CreateBillingViewError::BillingViewHealthStatusException(inner) => {
131                Error::BillingViewHealthStatusException(inner)
132            }
133            crate::operation::create_billing_view::CreateBillingViewError::ConflictException(inner) => Error::ConflictException(inner),
134            crate::operation::create_billing_view::CreateBillingViewError::InternalServerException(inner) => Error::InternalServerException(inner),
135            crate::operation::create_billing_view::CreateBillingViewError::ResourceNotFoundException(inner) => {
136                Error::ResourceNotFoundException(inner)
137            }
138            crate::operation::create_billing_view::CreateBillingViewError::ServiceQuotaExceededException(inner) => {
139                Error::ServiceQuotaExceededException(inner)
140            }
141            crate::operation::create_billing_view::CreateBillingViewError::ThrottlingException(inner) => Error::ThrottlingException(inner),
142            crate::operation::create_billing_view::CreateBillingViewError::ValidationException(inner) => Error::ValidationException(inner),
143            crate::operation::create_billing_view::CreateBillingViewError::Unhandled(inner) => Error::Unhandled(inner),
144        }
145    }
146}
147impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_billing_view::DeleteBillingViewError, R>> for Error
148where
149    R: Send + Sync + std::fmt::Debug + 'static,
150{
151    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_billing_view::DeleteBillingViewError, R>) -> Self {
152        match err {
153            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
154            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
155                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
156                source: err.into(),
157            }),
158        }
159    }
160}
161impl From<crate::operation::delete_billing_view::DeleteBillingViewError> for Error {
162    fn from(err: crate::operation::delete_billing_view::DeleteBillingViewError) -> Self {
163        match err {
164            crate::operation::delete_billing_view::DeleteBillingViewError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
165            crate::operation::delete_billing_view::DeleteBillingViewError::ConflictException(inner) => Error::ConflictException(inner),
166            crate::operation::delete_billing_view::DeleteBillingViewError::InternalServerException(inner) => Error::InternalServerException(inner),
167            crate::operation::delete_billing_view::DeleteBillingViewError::ThrottlingException(inner) => Error::ThrottlingException(inner),
168            crate::operation::delete_billing_view::DeleteBillingViewError::ValidationException(inner) => Error::ValidationException(inner),
169            crate::operation::delete_billing_view::DeleteBillingViewError::Unhandled(inner) => Error::Unhandled(inner),
170        }
171    }
172}
173impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::disassociate_source_views::DisassociateSourceViewsError, R>>
174    for Error
175where
176    R: Send + Sync + std::fmt::Debug + 'static,
177{
178    fn from(
179        err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::disassociate_source_views::DisassociateSourceViewsError, R>,
180    ) -> Self {
181        match err {
182            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
183            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
184                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
185                source: err.into(),
186            }),
187        }
188    }
189}
190impl From<crate::operation::disassociate_source_views::DisassociateSourceViewsError> for Error {
191    fn from(err: crate::operation::disassociate_source_views::DisassociateSourceViewsError) -> Self {
192        match err {
193            crate::operation::disassociate_source_views::DisassociateSourceViewsError::AccessDeniedException(inner) => {
194                Error::AccessDeniedException(inner)
195            }
196            crate::operation::disassociate_source_views::DisassociateSourceViewsError::BillingViewHealthStatusException(inner) => {
197                Error::BillingViewHealthStatusException(inner)
198            }
199            crate::operation::disassociate_source_views::DisassociateSourceViewsError::ConflictException(inner) => Error::ConflictException(inner),
200            crate::operation::disassociate_source_views::DisassociateSourceViewsError::InternalServerException(inner) => {
201                Error::InternalServerException(inner)
202            }
203            crate::operation::disassociate_source_views::DisassociateSourceViewsError::ResourceNotFoundException(inner) => {
204                Error::ResourceNotFoundException(inner)
205            }
206            crate::operation::disassociate_source_views::DisassociateSourceViewsError::ThrottlingException(inner) => {
207                Error::ThrottlingException(inner)
208            }
209            crate::operation::disassociate_source_views::DisassociateSourceViewsError::ValidationException(inner) => {
210                Error::ValidationException(inner)
211            }
212            crate::operation::disassociate_source_views::DisassociateSourceViewsError::Unhandled(inner) => Error::Unhandled(inner),
213        }
214    }
215}
216impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_billing_view::GetBillingViewError, R>> for Error
217where
218    R: Send + Sync + std::fmt::Debug + 'static,
219{
220    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_billing_view::GetBillingViewError, R>) -> Self {
221        match err {
222            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
223            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
224                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
225                source: err.into(),
226            }),
227        }
228    }
229}
230impl From<crate::operation::get_billing_view::GetBillingViewError> for Error {
231    fn from(err: crate::operation::get_billing_view::GetBillingViewError) -> Self {
232        match err {
233            crate::operation::get_billing_view::GetBillingViewError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
234            crate::operation::get_billing_view::GetBillingViewError::InternalServerException(inner) => Error::InternalServerException(inner),
235            crate::operation::get_billing_view::GetBillingViewError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
236            crate::operation::get_billing_view::GetBillingViewError::ThrottlingException(inner) => Error::ThrottlingException(inner),
237            crate::operation::get_billing_view::GetBillingViewError::ValidationException(inner) => Error::ValidationException(inner),
238            crate::operation::get_billing_view::GetBillingViewError::Unhandled(inner) => Error::Unhandled(inner),
239        }
240    }
241}
242impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_resource_policy::GetResourcePolicyError, R>> for Error
243where
244    R: Send + Sync + std::fmt::Debug + 'static,
245{
246    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_resource_policy::GetResourcePolicyError, R>) -> Self {
247        match err {
248            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
249            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
250                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
251                source: err.into(),
252            }),
253        }
254    }
255}
256impl From<crate::operation::get_resource_policy::GetResourcePolicyError> for Error {
257    fn from(err: crate::operation::get_resource_policy::GetResourcePolicyError) -> Self {
258        match err {
259            crate::operation::get_resource_policy::GetResourcePolicyError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
260            crate::operation::get_resource_policy::GetResourcePolicyError::InternalServerException(inner) => Error::InternalServerException(inner),
261            crate::operation::get_resource_policy::GetResourcePolicyError::ResourceNotFoundException(inner) => {
262                Error::ResourceNotFoundException(inner)
263            }
264            crate::operation::get_resource_policy::GetResourcePolicyError::ThrottlingException(inner) => Error::ThrottlingException(inner),
265            crate::operation::get_resource_policy::GetResourcePolicyError::ValidationException(inner) => Error::ValidationException(inner),
266            crate::operation::get_resource_policy::GetResourcePolicyError::Unhandled(inner) => Error::Unhandled(inner),
267        }
268    }
269}
270impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_billing_views::ListBillingViewsError, R>> for Error
271where
272    R: Send + Sync + std::fmt::Debug + 'static,
273{
274    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_billing_views::ListBillingViewsError, R>) -> Self {
275        match err {
276            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
277            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
278                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
279                source: err.into(),
280            }),
281        }
282    }
283}
284impl From<crate::operation::list_billing_views::ListBillingViewsError> for Error {
285    fn from(err: crate::operation::list_billing_views::ListBillingViewsError) -> Self {
286        match err {
287            crate::operation::list_billing_views::ListBillingViewsError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
288            crate::operation::list_billing_views::ListBillingViewsError::InternalServerException(inner) => Error::InternalServerException(inner),
289            crate::operation::list_billing_views::ListBillingViewsError::ThrottlingException(inner) => Error::ThrottlingException(inner),
290            crate::operation::list_billing_views::ListBillingViewsError::ValidationException(inner) => Error::ValidationException(inner),
291            crate::operation::list_billing_views::ListBillingViewsError::Unhandled(inner) => Error::Unhandled(inner),
292        }
293    }
294}
295impl<R>
296    From<
297        ::aws_smithy_runtime_api::client::result::SdkError<
298            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError,
299            R,
300        >,
301    > for Error
302where
303    R: Send + Sync + std::fmt::Debug + 'static,
304{
305    fn from(
306        err: ::aws_smithy_runtime_api::client::result::SdkError<
307            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError,
308            R,
309        >,
310    ) -> Self {
311        match err {
312            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
313            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
314                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
315                source: err.into(),
316            }),
317        }
318    }
319}
320impl From<crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError> for Error {
321    fn from(err: crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError) -> Self {
322        match err {
323            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError::AccessDeniedException(inner) => {
324                Error::AccessDeniedException(inner)
325            }
326            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError::InternalServerException(inner) => {
327                Error::InternalServerException(inner)
328            }
329            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError::ResourceNotFoundException(inner) => {
330                Error::ResourceNotFoundException(inner)
331            }
332            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError::ThrottlingException(inner) => {
333                Error::ThrottlingException(inner)
334            }
335            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError::ValidationException(inner) => {
336                Error::ValidationException(inner)
337            }
338            crate::operation::list_source_views_for_billing_view::ListSourceViewsForBillingViewError::Unhandled(inner) => Error::Unhandled(inner),
339        }
340    }
341}
342impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_tags_for_resource::ListTagsForResourceError, R>> for Error
343where
344    R: Send + Sync + std::fmt::Debug + 'static,
345{
346    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_tags_for_resource::ListTagsForResourceError, R>) -> Self {
347        match err {
348            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
349            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
350                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
351                source: err.into(),
352            }),
353        }
354    }
355}
356impl From<crate::operation::list_tags_for_resource::ListTagsForResourceError> for Error {
357    fn from(err: crate::operation::list_tags_for_resource::ListTagsForResourceError) -> Self {
358        match err {
359            crate::operation::list_tags_for_resource::ListTagsForResourceError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
360            crate::operation::list_tags_for_resource::ListTagsForResourceError::InternalServerException(inner) => {
361                Error::InternalServerException(inner)
362            }
363            crate::operation::list_tags_for_resource::ListTagsForResourceError::ResourceNotFoundException(inner) => {
364                Error::ResourceNotFoundException(inner)
365            }
366            crate::operation::list_tags_for_resource::ListTagsForResourceError::ThrottlingException(inner) => Error::ThrottlingException(inner),
367            crate::operation::list_tags_for_resource::ListTagsForResourceError::ValidationException(inner) => Error::ValidationException(inner),
368            crate::operation::list_tags_for_resource::ListTagsForResourceError::Unhandled(inner) => Error::Unhandled(inner),
369        }
370    }
371}
372impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::tag_resource::TagResourceError, R>> for Error
373where
374    R: Send + Sync + std::fmt::Debug + 'static,
375{
376    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::tag_resource::TagResourceError, R>) -> Self {
377        match err {
378            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
379            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
380                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
381                source: err.into(),
382            }),
383        }
384    }
385}
386impl From<crate::operation::tag_resource::TagResourceError> for Error {
387    fn from(err: crate::operation::tag_resource::TagResourceError) -> Self {
388        match err {
389            crate::operation::tag_resource::TagResourceError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
390            crate::operation::tag_resource::TagResourceError::InternalServerException(inner) => Error::InternalServerException(inner),
391            crate::operation::tag_resource::TagResourceError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
392            crate::operation::tag_resource::TagResourceError::ThrottlingException(inner) => Error::ThrottlingException(inner),
393            crate::operation::tag_resource::TagResourceError::ValidationException(inner) => Error::ValidationException(inner),
394            crate::operation::tag_resource::TagResourceError::Unhandled(inner) => Error::Unhandled(inner),
395        }
396    }
397}
398impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::untag_resource::UntagResourceError, R>> for Error
399where
400    R: Send + Sync + std::fmt::Debug + 'static,
401{
402    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::untag_resource::UntagResourceError, R>) -> Self {
403        match err {
404            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
405            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
406                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
407                source: err.into(),
408            }),
409        }
410    }
411}
412impl From<crate::operation::untag_resource::UntagResourceError> for Error {
413    fn from(err: crate::operation::untag_resource::UntagResourceError) -> Self {
414        match err {
415            crate::operation::untag_resource::UntagResourceError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
416            crate::operation::untag_resource::UntagResourceError::InternalServerException(inner) => Error::InternalServerException(inner),
417            crate::operation::untag_resource::UntagResourceError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
418            crate::operation::untag_resource::UntagResourceError::ThrottlingException(inner) => Error::ThrottlingException(inner),
419            crate::operation::untag_resource::UntagResourceError::ValidationException(inner) => Error::ValidationException(inner),
420            crate::operation::untag_resource::UntagResourceError::Unhandled(inner) => Error::Unhandled(inner),
421        }
422    }
423}
424impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::update_billing_view::UpdateBillingViewError, R>> for Error
425where
426    R: Send + Sync + std::fmt::Debug + 'static,
427{
428    fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::update_billing_view::UpdateBillingViewError, R>) -> Self {
429        match err {
430            ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
431            _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
432                meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
433                source: err.into(),
434            }),
435        }
436    }
437}
438impl From<crate::operation::update_billing_view::UpdateBillingViewError> for Error {
439    fn from(err: crate::operation::update_billing_view::UpdateBillingViewError) -> Self {
440        match err {
441            crate::operation::update_billing_view::UpdateBillingViewError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
442            crate::operation::update_billing_view::UpdateBillingViewError::BillingViewHealthStatusException(inner) => {
443                Error::BillingViewHealthStatusException(inner)
444            }
445            crate::operation::update_billing_view::UpdateBillingViewError::ConflictException(inner) => Error::ConflictException(inner),
446            crate::operation::update_billing_view::UpdateBillingViewError::InternalServerException(inner) => Error::InternalServerException(inner),
447            crate::operation::update_billing_view::UpdateBillingViewError::ResourceNotFoundException(inner) => {
448                Error::ResourceNotFoundException(inner)
449            }
450            crate::operation::update_billing_view::UpdateBillingViewError::ServiceQuotaExceededException(inner) => {
451                Error::ServiceQuotaExceededException(inner)
452            }
453            crate::operation::update_billing_view::UpdateBillingViewError::ThrottlingException(inner) => Error::ThrottlingException(inner),
454            crate::operation::update_billing_view::UpdateBillingViewError::ValidationException(inner) => Error::ValidationException(inner),
455            crate::operation::update_billing_view::UpdateBillingViewError::Unhandled(inner) => Error::Unhandled(inner),
456        }
457    }
458}
459impl ::std::error::Error for Error {
460    fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
461        match self {
462            Error::AccessDeniedException(inner) => inner.source(),
463            Error::BillingViewHealthStatusException(inner) => inner.source(),
464            Error::ConflictException(inner) => inner.source(),
465            Error::InternalServerException(inner) => inner.source(),
466            Error::ResourceNotFoundException(inner) => inner.source(),
467            Error::ServiceQuotaExceededException(inner) => inner.source(),
468            Error::ThrottlingException(inner) => inner.source(),
469            Error::ValidationException(inner) => inner.source(),
470            Error::Unhandled(inner) => ::std::option::Option::Some(&*inner.source),
471        }
472    }
473}
474impl ::aws_types::request_id::RequestId for Error {
475    fn request_id(&self) -> Option<&str> {
476        match self {
477            Self::AccessDeniedException(e) => e.request_id(),
478            Self::BillingViewHealthStatusException(e) => e.request_id(),
479            Self::ConflictException(e) => e.request_id(),
480            Self::InternalServerException(e) => e.request_id(),
481            Self::ResourceNotFoundException(e) => e.request_id(),
482            Self::ServiceQuotaExceededException(e) => e.request_id(),
483            Self::ThrottlingException(e) => e.request_id(),
484            Self::ValidationException(e) => e.request_id(),
485            Self::Unhandled(e) => e.meta.request_id(),
486        }
487    }
488}