1#[non_exhaustive]
4#[derive(::std::fmt::Debug)]
5pub enum Error {
6 AccessDeniedException(crate::types::error::AccessDeniedException),
9 ConflictException(crate::types::error::ConflictException),
12 InternalServerException(crate::types::error::InternalServerException),
15 ResourceNotFoundException(crate::types::error::ResourceNotFoundException),
18 ServiceQuotaExceededException(crate::types::error::ServiceQuotaExceededException),
21 ThrottlingException(crate::types::error::ThrottlingException),
24 ValidationException(crate::types::error::ValidationException),
27 #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
29 variable wildcard pattern and check `.code()`:
30 \
31 `err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
32 \
33 See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-Error) for what information is available for the error.")]
34 Unhandled(crate::error::sealed_unhandled::Unhandled),
35}
36impl ::std::fmt::Display for Error {
37 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
38 match self {
39 Error::AccessDeniedException(inner) => inner.fmt(f),
40 Error::ConflictException(inner) => inner.fmt(f),
41 Error::InternalServerException(inner) => inner.fmt(f),
42 Error::ResourceNotFoundException(inner) => inner.fmt(f),
43 Error::ServiceQuotaExceededException(inner) => inner.fmt(f),
44 Error::ThrottlingException(inner) => inner.fmt(f),
45 Error::ValidationException(inner) => inner.fmt(f),
46 Error::Unhandled(_) => {
47 if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
48 write!(f, "unhandled error ({code})")
49 } else {
50 f.write_str("unhandled error")
51 }
52 }
53 }
54 }
55}
56impl From<::aws_smithy_types::error::operation::BuildError> for Error {
57 fn from(value: ::aws_smithy_types::error::operation::BuildError) -> Self {
58 Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
59 source: value.into(),
60 meta: ::std::default::Default::default(),
61 })
62 }
63}
64impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for Error {
65 fn meta(&self) -> &::aws_smithy_types::error::metadata::ErrorMetadata {
66 match self {
67 Self::AccessDeniedException(inner) => inner.meta(),
68 Self::ConflictException(inner) => inner.meta(),
69 Self::InternalServerException(inner) => inner.meta(),
70 Self::ResourceNotFoundException(inner) => inner.meta(),
71 Self::ServiceQuotaExceededException(inner) => inner.meta(),
72 Self::ThrottlingException(inner) => inner.meta(),
73 Self::ValidationException(inner) => inner.meta(),
74 Self::Unhandled(inner) => &inner.meta,
75 }
76 }
77}
78impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError, R>>
79 for Error
80where
81 R: Send + Sync + std::fmt::Debug + 'static,
82{
83 fn from(
84 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError, R>,
85 ) -> Self {
86 match err {
87 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
88 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
89 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
90 source: err.into(),
91 }),
92 }
93 }
94}
95impl From<crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError> for Error {
96 fn from(err: crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError) -> Self {
97 match err {
98 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::AccessDeniedException(inner) => {
99 Error::AccessDeniedException(inner)
100 }
101 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::ConflictException(inner) => {
102 Error::ConflictException(inner)
103 }
104 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::InternalServerException(inner) => {
105 Error::InternalServerException(inner)
106 }
107 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::ResourceNotFoundException(inner) => {
108 Error::ResourceNotFoundException(inner)
109 }
110 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::ThrottlingException(inner) => {
111 Error::ThrottlingException(inner)
112 }
113 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::ValidationException(inner) => {
114 Error::ValidationException(inner)
115 }
116 crate::operation::accept_engagement_invitation::AcceptEngagementInvitationError::Unhandled(inner) => Error::Unhandled(inner),
117 }
118 }
119}
120impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::assign_opportunity::AssignOpportunityError, R>> for Error
121where
122 R: Send + Sync + std::fmt::Debug + 'static,
123{
124 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::assign_opportunity::AssignOpportunityError, R>) -> Self {
125 match err {
126 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
127 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
128 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
129 source: err.into(),
130 }),
131 }
132 }
133}
134impl From<crate::operation::assign_opportunity::AssignOpportunityError> for Error {
135 fn from(err: crate::operation::assign_opportunity::AssignOpportunityError) -> Self {
136 match err {
137 crate::operation::assign_opportunity::AssignOpportunityError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
138 crate::operation::assign_opportunity::AssignOpportunityError::InternalServerException(inner) => Error::InternalServerException(inner),
139 crate::operation::assign_opportunity::AssignOpportunityError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
140 crate::operation::assign_opportunity::AssignOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
141 crate::operation::assign_opportunity::AssignOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
142 crate::operation::assign_opportunity::AssignOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
143 }
144 }
145}
146impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::associate_opportunity::AssociateOpportunityError, R>> for Error
147where
148 R: Send + Sync + std::fmt::Debug + 'static,
149{
150 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::associate_opportunity::AssociateOpportunityError, R>) -> Self {
151 match err {
152 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
153 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
154 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
155 source: err.into(),
156 }),
157 }
158 }
159}
160impl From<crate::operation::associate_opportunity::AssociateOpportunityError> for Error {
161 fn from(err: crate::operation::associate_opportunity::AssociateOpportunityError) -> Self {
162 match err {
163 crate::operation::associate_opportunity::AssociateOpportunityError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
164 crate::operation::associate_opportunity::AssociateOpportunityError::InternalServerException(inner) => {
165 Error::InternalServerException(inner)
166 }
167 crate::operation::associate_opportunity::AssociateOpportunityError::ResourceNotFoundException(inner) => {
168 Error::ResourceNotFoundException(inner)
169 }
170 crate::operation::associate_opportunity::AssociateOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
171 crate::operation::associate_opportunity::AssociateOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
172 crate::operation::associate_opportunity::AssociateOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
173 }
174 }
175}
176impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_engagement::CreateEngagementError, R>> for Error
177where
178 R: Send + Sync + std::fmt::Debug + 'static,
179{
180 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_engagement::CreateEngagementError, R>) -> 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::create_engagement::CreateEngagementError> for Error {
191 fn from(err: crate::operation::create_engagement::CreateEngagementError) -> Self {
192 match err {
193 crate::operation::create_engagement::CreateEngagementError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
194 crate::operation::create_engagement::CreateEngagementError::ConflictException(inner) => Error::ConflictException(inner),
195 crate::operation::create_engagement::CreateEngagementError::InternalServerException(inner) => Error::InternalServerException(inner),
196 crate::operation::create_engagement::CreateEngagementError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
197 crate::operation::create_engagement::CreateEngagementError::ServiceQuotaExceededException(inner) => {
198 Error::ServiceQuotaExceededException(inner)
199 }
200 crate::operation::create_engagement::CreateEngagementError::ThrottlingException(inner) => Error::ThrottlingException(inner),
201 crate::operation::create_engagement::CreateEngagementError::ValidationException(inner) => Error::ValidationException(inner),
202 crate::operation::create_engagement::CreateEngagementError::Unhandled(inner) => Error::Unhandled(inner),
203 }
204 }
205}
206impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_engagement_context::CreateEngagementContextError, R>>
207 for Error
208where
209 R: Send + Sync + std::fmt::Debug + 'static,
210{
211 fn from(
212 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_engagement_context::CreateEngagementContextError, R>,
213 ) -> Self {
214 match err {
215 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
216 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
217 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
218 source: err.into(),
219 }),
220 }
221 }
222}
223impl From<crate::operation::create_engagement_context::CreateEngagementContextError> for Error {
224 fn from(err: crate::operation::create_engagement_context::CreateEngagementContextError) -> Self {
225 match err {
226 crate::operation::create_engagement_context::CreateEngagementContextError::AccessDeniedException(inner) => {
227 Error::AccessDeniedException(inner)
228 }
229 crate::operation::create_engagement_context::CreateEngagementContextError::ConflictException(inner) => Error::ConflictException(inner),
230 crate::operation::create_engagement_context::CreateEngagementContextError::InternalServerException(inner) => {
231 Error::InternalServerException(inner)
232 }
233 crate::operation::create_engagement_context::CreateEngagementContextError::ResourceNotFoundException(inner) => {
234 Error::ResourceNotFoundException(inner)
235 }
236 crate::operation::create_engagement_context::CreateEngagementContextError::ServiceQuotaExceededException(inner) => {
237 Error::ServiceQuotaExceededException(inner)
238 }
239 crate::operation::create_engagement_context::CreateEngagementContextError::ThrottlingException(inner) => {
240 Error::ThrottlingException(inner)
241 }
242 crate::operation::create_engagement_context::CreateEngagementContextError::ValidationException(inner) => {
243 Error::ValidationException(inner)
244 }
245 crate::operation::create_engagement_context::CreateEngagementContextError::Unhandled(inner) => Error::Unhandled(inner),
246 }
247 }
248}
249impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_engagement_invitation::CreateEngagementInvitationError, R>>
250 for Error
251where
252 R: Send + Sync + std::fmt::Debug + 'static,
253{
254 fn from(
255 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_engagement_invitation::CreateEngagementInvitationError, R>,
256 ) -> Self {
257 match err {
258 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
259 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
260 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
261 source: err.into(),
262 }),
263 }
264 }
265}
266impl From<crate::operation::create_engagement_invitation::CreateEngagementInvitationError> for Error {
267 fn from(err: crate::operation::create_engagement_invitation::CreateEngagementInvitationError) -> Self {
268 match err {
269 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::AccessDeniedException(inner) => {
270 Error::AccessDeniedException(inner)
271 }
272 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::ConflictException(inner) => {
273 Error::ConflictException(inner)
274 }
275 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::InternalServerException(inner) => {
276 Error::InternalServerException(inner)
277 }
278 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::ResourceNotFoundException(inner) => {
279 Error::ResourceNotFoundException(inner)
280 }
281 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::ServiceQuotaExceededException(inner) => {
282 Error::ServiceQuotaExceededException(inner)
283 }
284 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::ThrottlingException(inner) => {
285 Error::ThrottlingException(inner)
286 }
287 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::ValidationException(inner) => {
288 Error::ValidationException(inner)
289 }
290 crate::operation::create_engagement_invitation::CreateEngagementInvitationError::Unhandled(inner) => Error::Unhandled(inner),
291 }
292 }
293}
294impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_opportunity::CreateOpportunityError, R>> for Error
295where
296 R: Send + Sync + std::fmt::Debug + 'static,
297{
298 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_opportunity::CreateOpportunityError, R>) -> Self {
299 match err {
300 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
301 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
302 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
303 source: err.into(),
304 }),
305 }
306 }
307}
308impl From<crate::operation::create_opportunity::CreateOpportunityError> for Error {
309 fn from(err: crate::operation::create_opportunity::CreateOpportunityError) -> Self {
310 match err {
311 crate::operation::create_opportunity::CreateOpportunityError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
312 crate::operation::create_opportunity::CreateOpportunityError::ConflictException(inner) => Error::ConflictException(inner),
313 crate::operation::create_opportunity::CreateOpportunityError::InternalServerException(inner) => Error::InternalServerException(inner),
314 crate::operation::create_opportunity::CreateOpportunityError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
315 crate::operation::create_opportunity::CreateOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
316 crate::operation::create_opportunity::CreateOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
317 crate::operation::create_opportunity::CreateOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
318 }
319 }
320}
321impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_resource_snapshot::CreateResourceSnapshotError, R>> for Error
322where
323 R: Send + Sync + std::fmt::Debug + 'static,
324{
325 fn from(
326 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_resource_snapshot::CreateResourceSnapshotError, R>,
327 ) -> Self {
328 match err {
329 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
330 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
331 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
332 source: err.into(),
333 }),
334 }
335 }
336}
337impl From<crate::operation::create_resource_snapshot::CreateResourceSnapshotError> for Error {
338 fn from(err: crate::operation::create_resource_snapshot::CreateResourceSnapshotError) -> Self {
339 match err {
340 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::AccessDeniedException(inner) => {
341 Error::AccessDeniedException(inner)
342 }
343 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::ConflictException(inner) => Error::ConflictException(inner),
344 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::InternalServerException(inner) => {
345 Error::InternalServerException(inner)
346 }
347 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::ResourceNotFoundException(inner) => {
348 Error::ResourceNotFoundException(inner)
349 }
350 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::ServiceQuotaExceededException(inner) => {
351 Error::ServiceQuotaExceededException(inner)
352 }
353 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::ThrottlingException(inner) => Error::ThrottlingException(inner),
354 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::ValidationException(inner) => Error::ValidationException(inner),
355 crate::operation::create_resource_snapshot::CreateResourceSnapshotError::Unhandled(inner) => Error::Unhandled(inner),
356 }
357 }
358}
359impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError, R>>
360 for Error
361where
362 R: Send + Sync + std::fmt::Debug + 'static,
363{
364 fn from(
365 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError, R>,
366 ) -> Self {
367 match err {
368 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
369 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
370 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
371 source: err.into(),
372 }),
373 }
374 }
375}
376impl From<crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError> for Error {
377 fn from(err: crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError) -> Self {
378 match err {
379 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::AccessDeniedException(inner) => {
380 Error::AccessDeniedException(inner)
381 }
382 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::ConflictException(inner) => {
383 Error::ConflictException(inner)
384 }
385 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::InternalServerException(inner) => {
386 Error::InternalServerException(inner)
387 }
388 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::ResourceNotFoundException(inner) => {
389 Error::ResourceNotFoundException(inner)
390 }
391 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::ServiceQuotaExceededException(inner) => {
392 Error::ServiceQuotaExceededException(inner)
393 }
394 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::ThrottlingException(inner) => {
395 Error::ThrottlingException(inner)
396 }
397 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::ValidationException(inner) => {
398 Error::ValidationException(inner)
399 }
400 crate::operation::create_resource_snapshot_job::CreateResourceSnapshotJobError::Unhandled(inner) => Error::Unhandled(inner),
401 }
402 }
403}
404impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError, R>>
405 for Error
406where
407 R: Send + Sync + std::fmt::Debug + 'static,
408{
409 fn from(
410 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError, R>,
411 ) -> Self {
412 match err {
413 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
414 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
415 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
416 source: err.into(),
417 }),
418 }
419 }
420}
421impl From<crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError> for Error {
422 fn from(err: crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError) -> Self {
423 match err {
424 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::AccessDeniedException(inner) => {
425 Error::AccessDeniedException(inner)
426 }
427 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::ConflictException(inner) => {
428 Error::ConflictException(inner)
429 }
430 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::InternalServerException(inner) => {
431 Error::InternalServerException(inner)
432 }
433 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::ResourceNotFoundException(inner) => {
434 Error::ResourceNotFoundException(inner)
435 }
436 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::ThrottlingException(inner) => {
437 Error::ThrottlingException(inner)
438 }
439 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::ValidationException(inner) => {
440 Error::ValidationException(inner)
441 }
442 crate::operation::delete_resource_snapshot_job::DeleteResourceSnapshotJobError::Unhandled(inner) => Error::Unhandled(inner),
443 }
444 }
445}
446impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::disassociate_opportunity::DisassociateOpportunityError, R>>
447 for Error
448where
449 R: Send + Sync + std::fmt::Debug + 'static,
450{
451 fn from(
452 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::disassociate_opportunity::DisassociateOpportunityError, R>,
453 ) -> Self {
454 match err {
455 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
456 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
457 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
458 source: err.into(),
459 }),
460 }
461 }
462}
463impl From<crate::operation::disassociate_opportunity::DisassociateOpportunityError> for Error {
464 fn from(err: crate::operation::disassociate_opportunity::DisassociateOpportunityError) -> Self {
465 match err {
466 crate::operation::disassociate_opportunity::DisassociateOpportunityError::AccessDeniedException(inner) => {
467 Error::AccessDeniedException(inner)
468 }
469 crate::operation::disassociate_opportunity::DisassociateOpportunityError::InternalServerException(inner) => {
470 Error::InternalServerException(inner)
471 }
472 crate::operation::disassociate_opportunity::DisassociateOpportunityError::ResourceNotFoundException(inner) => {
473 Error::ResourceNotFoundException(inner)
474 }
475 crate::operation::disassociate_opportunity::DisassociateOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
476 crate::operation::disassociate_opportunity::DisassociateOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
477 crate::operation::disassociate_opportunity::DisassociateOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
478 }
479 }
480}
481impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError, R>>
482 for Error
483where
484 R: Send + Sync + std::fmt::Debug + 'static,
485{
486 fn from(
487 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError, R>,
488 ) -> Self {
489 match err {
490 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
491 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
492 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
493 source: err.into(),
494 }),
495 }
496 }
497}
498impl From<crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError> for Error {
499 fn from(err: crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError) -> Self {
500 match err {
501 crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError::AccessDeniedException(inner) => {
502 Error::AccessDeniedException(inner)
503 }
504 crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError::InternalServerException(inner) => {
505 Error::InternalServerException(inner)
506 }
507 crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError::ResourceNotFoundException(inner) => {
508 Error::ResourceNotFoundException(inner)
509 }
510 crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError::ThrottlingException(inner) => {
511 Error::ThrottlingException(inner)
512 }
513 crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError::ValidationException(inner) => {
514 Error::ValidationException(inner)
515 }
516 crate::operation::get_aws_opportunity_summary::GetAwsOpportunitySummaryError::Unhandled(inner) => Error::Unhandled(inner),
517 }
518 }
519}
520impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_engagement::GetEngagementError, R>> for Error
521where
522 R: Send + Sync + std::fmt::Debug + 'static,
523{
524 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_engagement::GetEngagementError, R>) -> Self {
525 match err {
526 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
527 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
528 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
529 source: err.into(),
530 }),
531 }
532 }
533}
534impl From<crate::operation::get_engagement::GetEngagementError> for Error {
535 fn from(err: crate::operation::get_engagement::GetEngagementError) -> Self {
536 match err {
537 crate::operation::get_engagement::GetEngagementError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
538 crate::operation::get_engagement::GetEngagementError::InternalServerException(inner) => Error::InternalServerException(inner),
539 crate::operation::get_engagement::GetEngagementError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
540 crate::operation::get_engagement::GetEngagementError::ThrottlingException(inner) => Error::ThrottlingException(inner),
541 crate::operation::get_engagement::GetEngagementError::ValidationException(inner) => Error::ValidationException(inner),
542 crate::operation::get_engagement::GetEngagementError::Unhandled(inner) => Error::Unhandled(inner),
543 }
544 }
545}
546impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_engagement_invitation::GetEngagementInvitationError, R>>
547 for Error
548where
549 R: Send + Sync + std::fmt::Debug + 'static,
550{
551 fn from(
552 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_engagement_invitation::GetEngagementInvitationError, R>,
553 ) -> Self {
554 match err {
555 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
556 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
557 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
558 source: err.into(),
559 }),
560 }
561 }
562}
563impl From<crate::operation::get_engagement_invitation::GetEngagementInvitationError> for Error {
564 fn from(err: crate::operation::get_engagement_invitation::GetEngagementInvitationError) -> Self {
565 match err {
566 crate::operation::get_engagement_invitation::GetEngagementInvitationError::AccessDeniedException(inner) => {
567 Error::AccessDeniedException(inner)
568 }
569 crate::operation::get_engagement_invitation::GetEngagementInvitationError::InternalServerException(inner) => {
570 Error::InternalServerException(inner)
571 }
572 crate::operation::get_engagement_invitation::GetEngagementInvitationError::ResourceNotFoundException(inner) => {
573 Error::ResourceNotFoundException(inner)
574 }
575 crate::operation::get_engagement_invitation::GetEngagementInvitationError::ThrottlingException(inner) => {
576 Error::ThrottlingException(inner)
577 }
578 crate::operation::get_engagement_invitation::GetEngagementInvitationError::ValidationException(inner) => {
579 Error::ValidationException(inner)
580 }
581 crate::operation::get_engagement_invitation::GetEngagementInvitationError::Unhandled(inner) => Error::Unhandled(inner),
582 }
583 }
584}
585impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_opportunity::GetOpportunityError, R>> for Error
586where
587 R: Send + Sync + std::fmt::Debug + 'static,
588{
589 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_opportunity::GetOpportunityError, R>) -> Self {
590 match err {
591 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
592 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
593 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
594 source: err.into(),
595 }),
596 }
597 }
598}
599impl From<crate::operation::get_opportunity::GetOpportunityError> for Error {
600 fn from(err: crate::operation::get_opportunity::GetOpportunityError) -> Self {
601 match err {
602 crate::operation::get_opportunity::GetOpportunityError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
603 crate::operation::get_opportunity::GetOpportunityError::InternalServerException(inner) => Error::InternalServerException(inner),
604 crate::operation::get_opportunity::GetOpportunityError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
605 crate::operation::get_opportunity::GetOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
606 crate::operation::get_opportunity::GetOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
607 crate::operation::get_opportunity::GetOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
608 }
609 }
610}
611impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_resource_snapshot::GetResourceSnapshotError, R>> for Error
612where
613 R: Send + Sync + std::fmt::Debug + 'static,
614{
615 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_resource_snapshot::GetResourceSnapshotError, R>) -> Self {
616 match err {
617 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
618 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
619 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
620 source: err.into(),
621 }),
622 }
623 }
624}
625impl From<crate::operation::get_resource_snapshot::GetResourceSnapshotError> for Error {
626 fn from(err: crate::operation::get_resource_snapshot::GetResourceSnapshotError) -> Self {
627 match err {
628 crate::operation::get_resource_snapshot::GetResourceSnapshotError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
629 crate::operation::get_resource_snapshot::GetResourceSnapshotError::InternalServerException(inner) => {
630 Error::InternalServerException(inner)
631 }
632 crate::operation::get_resource_snapshot::GetResourceSnapshotError::ResourceNotFoundException(inner) => {
633 Error::ResourceNotFoundException(inner)
634 }
635 crate::operation::get_resource_snapshot::GetResourceSnapshotError::ThrottlingException(inner) => Error::ThrottlingException(inner),
636 crate::operation::get_resource_snapshot::GetResourceSnapshotError::ValidationException(inner) => Error::ValidationException(inner),
637 crate::operation::get_resource_snapshot::GetResourceSnapshotError::Unhandled(inner) => Error::Unhandled(inner),
638 }
639 }
640}
641impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError, R>>
642 for Error
643where
644 R: Send + Sync + std::fmt::Debug + 'static,
645{
646 fn from(
647 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError, R>,
648 ) -> Self {
649 match err {
650 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
651 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
652 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
653 source: err.into(),
654 }),
655 }
656 }
657}
658impl From<crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError> for Error {
659 fn from(err: crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError) -> Self {
660 match err {
661 crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError::AccessDeniedException(inner) => {
662 Error::AccessDeniedException(inner)
663 }
664 crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError::InternalServerException(inner) => {
665 Error::InternalServerException(inner)
666 }
667 crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError::ResourceNotFoundException(inner) => {
668 Error::ResourceNotFoundException(inner)
669 }
670 crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError::ThrottlingException(inner) => Error::ThrottlingException(inner),
671 crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError::ValidationException(inner) => Error::ValidationException(inner),
672 crate::operation::get_resource_snapshot_job::GetResourceSnapshotJobError::Unhandled(inner) => Error::Unhandled(inner),
673 }
674 }
675}
676impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_selling_system_settings::GetSellingSystemSettingsError, R>>
677 for Error
678where
679 R: Send + Sync + std::fmt::Debug + 'static,
680{
681 fn from(
682 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::get_selling_system_settings::GetSellingSystemSettingsError, R>,
683 ) -> Self {
684 match err {
685 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
686 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
687 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
688 source: err.into(),
689 }),
690 }
691 }
692}
693impl From<crate::operation::get_selling_system_settings::GetSellingSystemSettingsError> for Error {
694 fn from(err: crate::operation::get_selling_system_settings::GetSellingSystemSettingsError) -> Self {
695 match err {
696 crate::operation::get_selling_system_settings::GetSellingSystemSettingsError::AccessDeniedException(inner) => {
697 Error::AccessDeniedException(inner)
698 }
699 crate::operation::get_selling_system_settings::GetSellingSystemSettingsError::InternalServerException(inner) => {
700 Error::InternalServerException(inner)
701 }
702 crate::operation::get_selling_system_settings::GetSellingSystemSettingsError::ResourceNotFoundException(inner) => {
703 Error::ResourceNotFoundException(inner)
704 }
705 crate::operation::get_selling_system_settings::GetSellingSystemSettingsError::ThrottlingException(inner) => {
706 Error::ThrottlingException(inner)
707 }
708 crate::operation::get_selling_system_settings::GetSellingSystemSettingsError::ValidationException(inner) => {
709 Error::ValidationException(inner)
710 }
711 crate::operation::get_selling_system_settings::GetSellingSystemSettingsError::Unhandled(inner) => Error::Unhandled(inner),
712 }
713 }
714}
715impl<R>
716 From<
717 ::aws_smithy_runtime_api::client::result::SdkError<
718 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError,
719 R,
720 >,
721 > for Error
722where
723 R: Send + Sync + std::fmt::Debug + 'static,
724{
725 fn from(
726 err: ::aws_smithy_runtime_api::client::result::SdkError<
727 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError,
728 R,
729 >,
730 ) -> Self {
731 match err {
732 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
733 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
734 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
735 source: err.into(),
736 }),
737 }
738 }
739}
740impl From<crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError> for Error {
741 fn from(err: crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError) -> Self {
742 match err {
743 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
744 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError::InternalServerException(inner) => Error::InternalServerException(inner),
745 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
746 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError::ThrottlingException(inner) => Error::ThrottlingException(inner),
747 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError::ValidationException(inner) => Error::ValidationException(inner),
748 crate::operation::list_engagement_by_accepting_invitation_tasks::ListEngagementByAcceptingInvitationTasksError::Unhandled(inner) => Error::Unhandled(inner),
749 }
750 }
751}
752impl<R>
753 From<
754 ::aws_smithy_runtime_api::client::result::SdkError<
755 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError,
756 R,
757 >,
758 > for Error
759where
760 R: Send + Sync + std::fmt::Debug + 'static,
761{
762 fn from(
763 err: ::aws_smithy_runtime_api::client::result::SdkError<
764 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError,
765 R,
766 >,
767 ) -> Self {
768 match err {
769 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
770 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
771 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
772 source: err.into(),
773 }),
774 }
775 }
776}
777impl From<crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError> for Error {
778 fn from(err: crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError) -> Self {
779 match err {
780 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError::AccessDeniedException(inner) => {
781 Error::AccessDeniedException(inner)
782 }
783 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError::InternalServerException(inner) => {
784 Error::InternalServerException(inner)
785 }
786 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError::ResourceNotFoundException(inner) => {
787 Error::ResourceNotFoundException(inner)
788 }
789 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError::ThrottlingException(inner) => {
790 Error::ThrottlingException(inner)
791 }
792 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError::ValidationException(inner) => {
793 Error::ValidationException(inner)
794 }
795 crate::operation::list_engagement_from_opportunity_tasks::ListEngagementFromOpportunityTasksError::Unhandled(inner) => {
796 Error::Unhandled(inner)
797 }
798 }
799 }
800}
801impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_engagement_invitations::ListEngagementInvitationsError, R>>
802 for Error
803where
804 R: Send + Sync + std::fmt::Debug + 'static,
805{
806 fn from(
807 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_engagement_invitations::ListEngagementInvitationsError, R>,
808 ) -> Self {
809 match err {
810 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
811 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
812 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
813 source: err.into(),
814 }),
815 }
816 }
817}
818impl From<crate::operation::list_engagement_invitations::ListEngagementInvitationsError> for Error {
819 fn from(err: crate::operation::list_engagement_invitations::ListEngagementInvitationsError) -> Self {
820 match err {
821 crate::operation::list_engagement_invitations::ListEngagementInvitationsError::AccessDeniedException(inner) => {
822 Error::AccessDeniedException(inner)
823 }
824 crate::operation::list_engagement_invitations::ListEngagementInvitationsError::InternalServerException(inner) => {
825 Error::InternalServerException(inner)
826 }
827 crate::operation::list_engagement_invitations::ListEngagementInvitationsError::ResourceNotFoundException(inner) => {
828 Error::ResourceNotFoundException(inner)
829 }
830 crate::operation::list_engagement_invitations::ListEngagementInvitationsError::ThrottlingException(inner) => {
831 Error::ThrottlingException(inner)
832 }
833 crate::operation::list_engagement_invitations::ListEngagementInvitationsError::ValidationException(inner) => {
834 Error::ValidationException(inner)
835 }
836 crate::operation::list_engagement_invitations::ListEngagementInvitationsError::Unhandled(inner) => Error::Unhandled(inner),
837 }
838 }
839}
840impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_engagement_members::ListEngagementMembersError, R>> for Error
841where
842 R: Send + Sync + std::fmt::Debug + 'static,
843{
844 fn from(
845 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_engagement_members::ListEngagementMembersError, R>,
846 ) -> Self {
847 match err {
848 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
849 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
850 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
851 source: err.into(),
852 }),
853 }
854 }
855}
856impl From<crate::operation::list_engagement_members::ListEngagementMembersError> for Error {
857 fn from(err: crate::operation::list_engagement_members::ListEngagementMembersError) -> Self {
858 match err {
859 crate::operation::list_engagement_members::ListEngagementMembersError::AccessDeniedException(inner) => {
860 Error::AccessDeniedException(inner)
861 }
862 crate::operation::list_engagement_members::ListEngagementMembersError::InternalServerException(inner) => {
863 Error::InternalServerException(inner)
864 }
865 crate::operation::list_engagement_members::ListEngagementMembersError::ResourceNotFoundException(inner) => {
866 Error::ResourceNotFoundException(inner)
867 }
868 crate::operation::list_engagement_members::ListEngagementMembersError::ThrottlingException(inner) => Error::ThrottlingException(inner),
869 crate::operation::list_engagement_members::ListEngagementMembersError::ValidationException(inner) => Error::ValidationException(inner),
870 crate::operation::list_engagement_members::ListEngagementMembersError::Unhandled(inner) => Error::Unhandled(inner),
871 }
872 }
873}
874impl<R>
875 From<
876 ::aws_smithy_runtime_api::client::result::SdkError<
877 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError,
878 R,
879 >,
880 > for Error
881where
882 R: Send + Sync + std::fmt::Debug + 'static,
883{
884 fn from(
885 err: ::aws_smithy_runtime_api::client::result::SdkError<
886 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError,
887 R,
888 >,
889 ) -> Self {
890 match err {
891 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
892 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
893 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
894 source: err.into(),
895 }),
896 }
897 }
898}
899impl From<crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError> for Error {
900 fn from(err: crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError) -> Self {
901 match err {
902 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError::AccessDeniedException(inner) => {
903 Error::AccessDeniedException(inner)
904 }
905 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError::InternalServerException(inner) => {
906 Error::InternalServerException(inner)
907 }
908 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError::ResourceNotFoundException(inner) => {
909 Error::ResourceNotFoundException(inner)
910 }
911 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError::ThrottlingException(inner) => {
912 Error::ThrottlingException(inner)
913 }
914 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError::ValidationException(inner) => {
915 Error::ValidationException(inner)
916 }
917 crate::operation::list_engagement_resource_associations::ListEngagementResourceAssociationsError::Unhandled(inner) => {
918 Error::Unhandled(inner)
919 }
920 }
921 }
922}
923impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_engagements::ListEngagementsError, R>> for Error
924where
925 R: Send + Sync + std::fmt::Debug + 'static,
926{
927 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_engagements::ListEngagementsError, R>) -> Self {
928 match err {
929 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
930 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
931 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
932 source: err.into(),
933 }),
934 }
935 }
936}
937impl From<crate::operation::list_engagements::ListEngagementsError> for Error {
938 fn from(err: crate::operation::list_engagements::ListEngagementsError) -> Self {
939 match err {
940 crate::operation::list_engagements::ListEngagementsError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
941 crate::operation::list_engagements::ListEngagementsError::InternalServerException(inner) => Error::InternalServerException(inner),
942 crate::operation::list_engagements::ListEngagementsError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
943 crate::operation::list_engagements::ListEngagementsError::ThrottlingException(inner) => Error::ThrottlingException(inner),
944 crate::operation::list_engagements::ListEngagementsError::ValidationException(inner) => Error::ValidationException(inner),
945 crate::operation::list_engagements::ListEngagementsError::Unhandled(inner) => Error::Unhandled(inner),
946 }
947 }
948}
949impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_opportunities::ListOpportunitiesError, R>> for Error
950where
951 R: Send + Sync + std::fmt::Debug + 'static,
952{
953 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_opportunities::ListOpportunitiesError, R>) -> Self {
954 match err {
955 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
956 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
957 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
958 source: err.into(),
959 }),
960 }
961 }
962}
963impl From<crate::operation::list_opportunities::ListOpportunitiesError> for Error {
964 fn from(err: crate::operation::list_opportunities::ListOpportunitiesError) -> Self {
965 match err {
966 crate::operation::list_opportunities::ListOpportunitiesError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
967 crate::operation::list_opportunities::ListOpportunitiesError::InternalServerException(inner) => Error::InternalServerException(inner),
968 crate::operation::list_opportunities::ListOpportunitiesError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
969 crate::operation::list_opportunities::ListOpportunitiesError::ThrottlingException(inner) => Error::ThrottlingException(inner),
970 crate::operation::list_opportunities::ListOpportunitiesError::ValidationException(inner) => Error::ValidationException(inner),
971 crate::operation::list_opportunities::ListOpportunitiesError::Unhandled(inner) => Error::Unhandled(inner),
972 }
973 }
974}
975impl<R>
976 From<
977 ::aws_smithy_runtime_api::client::result::SdkError<
978 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError,
979 R,
980 >,
981 > for Error
982where
983 R: Send + Sync + std::fmt::Debug + 'static,
984{
985 fn from(
986 err: ::aws_smithy_runtime_api::client::result::SdkError<
987 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError,
988 R,
989 >,
990 ) -> Self {
991 match err {
992 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
993 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
994 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
995 source: err.into(),
996 }),
997 }
998 }
999}
1000impl From<crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError> for Error {
1001 fn from(err: crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError) -> Self {
1002 match err {
1003 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError::AccessDeniedException(inner) => {
1004 Error::AccessDeniedException(inner)
1005 }
1006 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError::InternalServerException(inner) => {
1007 Error::InternalServerException(inner)
1008 }
1009 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError::ResourceNotFoundException(inner) => {
1010 Error::ResourceNotFoundException(inner)
1011 }
1012 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError::ThrottlingException(inner) => {
1013 Error::ThrottlingException(inner)
1014 }
1015 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError::ValidationException(inner) => {
1016 Error::ValidationException(inner)
1017 }
1018 crate::operation::list_opportunity_from_engagement_tasks::ListOpportunityFromEngagementTasksError::Unhandled(inner) => {
1019 Error::Unhandled(inner)
1020 }
1021 }
1022 }
1023}
1024impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError, R>>
1025 for Error
1026where
1027 R: Send + Sync + std::fmt::Debug + 'static,
1028{
1029 fn from(
1030 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError, R>,
1031 ) -> Self {
1032 match err {
1033 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1034 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1035 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1036 source: err.into(),
1037 }),
1038 }
1039 }
1040}
1041impl From<crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError> for Error {
1042 fn from(err: crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError) -> Self {
1043 match err {
1044 crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError::AccessDeniedException(inner) => {
1045 Error::AccessDeniedException(inner)
1046 }
1047 crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError::InternalServerException(inner) => {
1048 Error::InternalServerException(inner)
1049 }
1050 crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError::ResourceNotFoundException(inner) => {
1051 Error::ResourceNotFoundException(inner)
1052 }
1053 crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError::ThrottlingException(inner) => {
1054 Error::ThrottlingException(inner)
1055 }
1056 crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError::ValidationException(inner) => {
1057 Error::ValidationException(inner)
1058 }
1059 crate::operation::list_resource_snapshot_jobs::ListResourceSnapshotJobsError::Unhandled(inner) => Error::Unhandled(inner),
1060 }
1061 }
1062}
1063impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_resource_snapshots::ListResourceSnapshotsError, R>> for Error
1064where
1065 R: Send + Sync + std::fmt::Debug + 'static,
1066{
1067 fn from(
1068 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_resource_snapshots::ListResourceSnapshotsError, R>,
1069 ) -> Self {
1070 match err {
1071 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1072 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1073 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1074 source: err.into(),
1075 }),
1076 }
1077 }
1078}
1079impl From<crate::operation::list_resource_snapshots::ListResourceSnapshotsError> for Error {
1080 fn from(err: crate::operation::list_resource_snapshots::ListResourceSnapshotsError) -> Self {
1081 match err {
1082 crate::operation::list_resource_snapshots::ListResourceSnapshotsError::AccessDeniedException(inner) => {
1083 Error::AccessDeniedException(inner)
1084 }
1085 crate::operation::list_resource_snapshots::ListResourceSnapshotsError::InternalServerException(inner) => {
1086 Error::InternalServerException(inner)
1087 }
1088 crate::operation::list_resource_snapshots::ListResourceSnapshotsError::ResourceNotFoundException(inner) => {
1089 Error::ResourceNotFoundException(inner)
1090 }
1091 crate::operation::list_resource_snapshots::ListResourceSnapshotsError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1092 crate::operation::list_resource_snapshots::ListResourceSnapshotsError::ValidationException(inner) => Error::ValidationException(inner),
1093 crate::operation::list_resource_snapshots::ListResourceSnapshotsError::Unhandled(inner) => Error::Unhandled(inner),
1094 }
1095 }
1096}
1097impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_solutions::ListSolutionsError, R>> for Error
1098where
1099 R: Send + Sync + std::fmt::Debug + 'static,
1100{
1101 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_solutions::ListSolutionsError, R>) -> Self {
1102 match err {
1103 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1104 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1105 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1106 source: err.into(),
1107 }),
1108 }
1109 }
1110}
1111impl From<crate::operation::list_solutions::ListSolutionsError> for Error {
1112 fn from(err: crate::operation::list_solutions::ListSolutionsError) -> Self {
1113 match err {
1114 crate::operation::list_solutions::ListSolutionsError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1115 crate::operation::list_solutions::ListSolutionsError::InternalServerException(inner) => Error::InternalServerException(inner),
1116 crate::operation::list_solutions::ListSolutionsError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
1117 crate::operation::list_solutions::ListSolutionsError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1118 crate::operation::list_solutions::ListSolutionsError::ValidationException(inner) => Error::ValidationException(inner),
1119 crate::operation::list_solutions::ListSolutionsError::Unhandled(inner) => Error::Unhandled(inner),
1120 }
1121 }
1122}
1123impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_tags_for_resource::ListTagsForResourceError, R>> for Error
1124where
1125 R: Send + Sync + std::fmt::Debug + 'static,
1126{
1127 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::list_tags_for_resource::ListTagsForResourceError, R>) -> Self {
1128 match err {
1129 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1130 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1131 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1132 source: err.into(),
1133 }),
1134 }
1135 }
1136}
1137impl From<crate::operation::list_tags_for_resource::ListTagsForResourceError> for Error {
1138 fn from(err: crate::operation::list_tags_for_resource::ListTagsForResourceError) -> Self {
1139 match err {
1140 crate::operation::list_tags_for_resource::ListTagsForResourceError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1141 crate::operation::list_tags_for_resource::ListTagsForResourceError::InternalServerException(inner) => {
1142 Error::InternalServerException(inner)
1143 }
1144 crate::operation::list_tags_for_resource::ListTagsForResourceError::ResourceNotFoundException(inner) => {
1145 Error::ResourceNotFoundException(inner)
1146 }
1147 crate::operation::list_tags_for_resource::ListTagsForResourceError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1148 crate::operation::list_tags_for_resource::ListTagsForResourceError::ValidationException(inner) => Error::ValidationException(inner),
1149 crate::operation::list_tags_for_resource::ListTagsForResourceError::Unhandled(inner) => Error::Unhandled(inner),
1150 }
1151 }
1152}
1153impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_selling_system_settings::PutSellingSystemSettingsError, R>>
1154 for Error
1155where
1156 R: Send + Sync + std::fmt::Debug + 'static,
1157{
1158 fn from(
1159 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::put_selling_system_settings::PutSellingSystemSettingsError, R>,
1160 ) -> Self {
1161 match err {
1162 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1163 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1164 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1165 source: err.into(),
1166 }),
1167 }
1168 }
1169}
1170impl From<crate::operation::put_selling_system_settings::PutSellingSystemSettingsError> for Error {
1171 fn from(err: crate::operation::put_selling_system_settings::PutSellingSystemSettingsError) -> Self {
1172 match err {
1173 crate::operation::put_selling_system_settings::PutSellingSystemSettingsError::AccessDeniedException(inner) => {
1174 Error::AccessDeniedException(inner)
1175 }
1176 crate::operation::put_selling_system_settings::PutSellingSystemSettingsError::InternalServerException(inner) => {
1177 Error::InternalServerException(inner)
1178 }
1179 crate::operation::put_selling_system_settings::PutSellingSystemSettingsError::ResourceNotFoundException(inner) => {
1180 Error::ResourceNotFoundException(inner)
1181 }
1182 crate::operation::put_selling_system_settings::PutSellingSystemSettingsError::ThrottlingException(inner) => {
1183 Error::ThrottlingException(inner)
1184 }
1185 crate::operation::put_selling_system_settings::PutSellingSystemSettingsError::ValidationException(inner) => {
1186 Error::ValidationException(inner)
1187 }
1188 crate::operation::put_selling_system_settings::PutSellingSystemSettingsError::Unhandled(inner) => Error::Unhandled(inner),
1189 }
1190 }
1191}
1192impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::reject_engagement_invitation::RejectEngagementInvitationError, R>>
1193 for Error
1194where
1195 R: Send + Sync + std::fmt::Debug + 'static,
1196{
1197 fn from(
1198 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::reject_engagement_invitation::RejectEngagementInvitationError, R>,
1199 ) -> Self {
1200 match err {
1201 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1202 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1203 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1204 source: err.into(),
1205 }),
1206 }
1207 }
1208}
1209impl From<crate::operation::reject_engagement_invitation::RejectEngagementInvitationError> for Error {
1210 fn from(err: crate::operation::reject_engagement_invitation::RejectEngagementInvitationError) -> Self {
1211 match err {
1212 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::AccessDeniedException(inner) => {
1213 Error::AccessDeniedException(inner)
1214 }
1215 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::ConflictException(inner) => {
1216 Error::ConflictException(inner)
1217 }
1218 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::InternalServerException(inner) => {
1219 Error::InternalServerException(inner)
1220 }
1221 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::ResourceNotFoundException(inner) => {
1222 Error::ResourceNotFoundException(inner)
1223 }
1224 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::ThrottlingException(inner) => {
1225 Error::ThrottlingException(inner)
1226 }
1227 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::ValidationException(inner) => {
1228 Error::ValidationException(inner)
1229 }
1230 crate::operation::reject_engagement_invitation::RejectEngagementInvitationError::Unhandled(inner) => Error::Unhandled(inner),
1231 }
1232 }
1233}
1234impl<R>
1235 From<
1236 ::aws_smithy_runtime_api::client::result::SdkError<
1237 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError,
1238 R,
1239 >,
1240 > for Error
1241where
1242 R: Send + Sync + std::fmt::Debug + 'static,
1243{
1244 fn from(
1245 err: ::aws_smithy_runtime_api::client::result::SdkError<
1246 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError,
1247 R,
1248 >,
1249 ) -> Self {
1250 match err {
1251 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1252 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1253 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1254 source: err.into(),
1255 }),
1256 }
1257 }
1258}
1259impl From<crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError> for Error {
1260 fn from(err: crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError) -> Self {
1261 match err {
1262 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1263 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::ConflictException(inner) => Error::ConflictException(inner),
1264 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::InternalServerException(inner) => Error::InternalServerException(inner),
1265 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
1266 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::ServiceQuotaExceededException(inner) => Error::ServiceQuotaExceededException(inner),
1267 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1268 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::ValidationException(inner) => Error::ValidationException(inner),
1269 crate::operation::start_engagement_by_accepting_invitation_task::StartEngagementByAcceptingInvitationTaskError::Unhandled(inner) => Error::Unhandled(inner),
1270 }
1271 }
1272}
1273impl<R>
1274 From<
1275 ::aws_smithy_runtime_api::client::result::SdkError<
1276 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError,
1277 R,
1278 >,
1279 > for Error
1280where
1281 R: Send + Sync + std::fmt::Debug + 'static,
1282{
1283 fn from(
1284 err: ::aws_smithy_runtime_api::client::result::SdkError<
1285 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError,
1286 R,
1287 >,
1288 ) -> Self {
1289 match err {
1290 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1291 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1292 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1293 source: err.into(),
1294 }),
1295 }
1296 }
1297}
1298impl From<crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError> for Error {
1299 fn from(err: crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError) -> Self {
1300 match err {
1301 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::AccessDeniedException(inner) => {
1302 Error::AccessDeniedException(inner)
1303 }
1304 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::ConflictException(inner) => {
1305 Error::ConflictException(inner)
1306 }
1307 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::InternalServerException(inner) => {
1308 Error::InternalServerException(inner)
1309 }
1310 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::ResourceNotFoundException(inner) => {
1311 Error::ResourceNotFoundException(inner)
1312 }
1313 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::ServiceQuotaExceededException(
1314 inner,
1315 ) => Error::ServiceQuotaExceededException(inner),
1316 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::ThrottlingException(inner) => {
1317 Error::ThrottlingException(inner)
1318 }
1319 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::ValidationException(inner) => {
1320 Error::ValidationException(inner)
1321 }
1322 crate::operation::start_engagement_from_opportunity_task::StartEngagementFromOpportunityTaskError::Unhandled(inner) => {
1323 Error::Unhandled(inner)
1324 }
1325 }
1326 }
1327}
1328impl<R>
1329 From<
1330 ::aws_smithy_runtime_api::client::result::SdkError<
1331 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError,
1332 R,
1333 >,
1334 > for Error
1335where
1336 R: Send + Sync + std::fmt::Debug + 'static,
1337{
1338 fn from(
1339 err: ::aws_smithy_runtime_api::client::result::SdkError<
1340 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError,
1341 R,
1342 >,
1343 ) -> Self {
1344 match err {
1345 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1346 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1347 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1348 source: err.into(),
1349 }),
1350 }
1351 }
1352}
1353impl From<crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError> for Error {
1354 fn from(err: crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError) -> Self {
1355 match err {
1356 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::AccessDeniedException(inner) => {
1357 Error::AccessDeniedException(inner)
1358 }
1359 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::ConflictException(inner) => {
1360 Error::ConflictException(inner)
1361 }
1362 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::InternalServerException(inner) => {
1363 Error::InternalServerException(inner)
1364 }
1365 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::ResourceNotFoundException(inner) => {
1366 Error::ResourceNotFoundException(inner)
1367 }
1368 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::ServiceQuotaExceededException(
1369 inner,
1370 ) => Error::ServiceQuotaExceededException(inner),
1371 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::ThrottlingException(inner) => {
1372 Error::ThrottlingException(inner)
1373 }
1374 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::ValidationException(inner) => {
1375 Error::ValidationException(inner)
1376 }
1377 crate::operation::start_opportunity_from_engagement_task::StartOpportunityFromEngagementTaskError::Unhandled(inner) => {
1378 Error::Unhandled(inner)
1379 }
1380 }
1381 }
1382}
1383impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError, R>>
1384 for Error
1385where
1386 R: Send + Sync + std::fmt::Debug + 'static,
1387{
1388 fn from(
1389 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError, R>,
1390 ) -> Self {
1391 match err {
1392 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1393 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1394 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1395 source: err.into(),
1396 }),
1397 }
1398 }
1399}
1400impl From<crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError> for Error {
1401 fn from(err: crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError) -> Self {
1402 match err {
1403 crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError::AccessDeniedException(inner) => {
1404 Error::AccessDeniedException(inner)
1405 }
1406 crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError::InternalServerException(inner) => {
1407 Error::InternalServerException(inner)
1408 }
1409 crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError::ResourceNotFoundException(inner) => {
1410 Error::ResourceNotFoundException(inner)
1411 }
1412 crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError::ThrottlingException(inner) => {
1413 Error::ThrottlingException(inner)
1414 }
1415 crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError::ValidationException(inner) => {
1416 Error::ValidationException(inner)
1417 }
1418 crate::operation::start_resource_snapshot_job::StartResourceSnapshotJobError::Unhandled(inner) => Error::Unhandled(inner),
1419 }
1420 }
1421}
1422impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError, R>>
1423 for Error
1424where
1425 R: Send + Sync + std::fmt::Debug + 'static,
1426{
1427 fn from(
1428 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError, R>,
1429 ) -> Self {
1430 match err {
1431 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1432 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1433 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1434 source: err.into(),
1435 }),
1436 }
1437 }
1438}
1439impl From<crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError> for Error {
1440 fn from(err: crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError) -> Self {
1441 match err {
1442 crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError::AccessDeniedException(inner) => {
1443 Error::AccessDeniedException(inner)
1444 }
1445 crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError::InternalServerException(inner) => {
1446 Error::InternalServerException(inner)
1447 }
1448 crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError::ResourceNotFoundException(inner) => {
1449 Error::ResourceNotFoundException(inner)
1450 }
1451 crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError::ThrottlingException(inner) => {
1452 Error::ThrottlingException(inner)
1453 }
1454 crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError::ValidationException(inner) => {
1455 Error::ValidationException(inner)
1456 }
1457 crate::operation::stop_resource_snapshot_job::StopResourceSnapshotJobError::Unhandled(inner) => Error::Unhandled(inner),
1458 }
1459 }
1460}
1461impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::submit_opportunity::SubmitOpportunityError, R>> for Error
1462where
1463 R: Send + Sync + std::fmt::Debug + 'static,
1464{
1465 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::submit_opportunity::SubmitOpportunityError, R>) -> Self {
1466 match err {
1467 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1468 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1469 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1470 source: err.into(),
1471 }),
1472 }
1473 }
1474}
1475impl From<crate::operation::submit_opportunity::SubmitOpportunityError> for Error {
1476 fn from(err: crate::operation::submit_opportunity::SubmitOpportunityError) -> Self {
1477 match err {
1478 crate::operation::submit_opportunity::SubmitOpportunityError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1479 crate::operation::submit_opportunity::SubmitOpportunityError::InternalServerException(inner) => Error::InternalServerException(inner),
1480 crate::operation::submit_opportunity::SubmitOpportunityError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
1481 crate::operation::submit_opportunity::SubmitOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1482 crate::operation::submit_opportunity::SubmitOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
1483 crate::operation::submit_opportunity::SubmitOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
1484 }
1485 }
1486}
1487impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::tag_resource::TagResourceError, R>> for Error
1488where
1489 R: Send + Sync + std::fmt::Debug + 'static,
1490{
1491 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::tag_resource::TagResourceError, R>) -> Self {
1492 match err {
1493 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1494 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1495 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1496 source: err.into(),
1497 }),
1498 }
1499 }
1500}
1501impl From<crate::operation::tag_resource::TagResourceError> for Error {
1502 fn from(err: crate::operation::tag_resource::TagResourceError) -> Self {
1503 match err {
1504 crate::operation::tag_resource::TagResourceError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1505 crate::operation::tag_resource::TagResourceError::ConflictException(inner) => Error::ConflictException(inner),
1506 crate::operation::tag_resource::TagResourceError::InternalServerException(inner) => Error::InternalServerException(inner),
1507 crate::operation::tag_resource::TagResourceError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
1508 crate::operation::tag_resource::TagResourceError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1509 crate::operation::tag_resource::TagResourceError::ValidationException(inner) => Error::ValidationException(inner),
1510 crate::operation::tag_resource::TagResourceError::Unhandled(inner) => Error::Unhandled(inner),
1511 }
1512 }
1513}
1514impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::untag_resource::UntagResourceError, R>> for Error
1515where
1516 R: Send + Sync + std::fmt::Debug + 'static,
1517{
1518 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::untag_resource::UntagResourceError, R>) -> Self {
1519 match err {
1520 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1521 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1522 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1523 source: err.into(),
1524 }),
1525 }
1526 }
1527}
1528impl From<crate::operation::untag_resource::UntagResourceError> for Error {
1529 fn from(err: crate::operation::untag_resource::UntagResourceError) -> Self {
1530 match err {
1531 crate::operation::untag_resource::UntagResourceError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1532 crate::operation::untag_resource::UntagResourceError::ConflictException(inner) => Error::ConflictException(inner),
1533 crate::operation::untag_resource::UntagResourceError::InternalServerException(inner) => Error::InternalServerException(inner),
1534 crate::operation::untag_resource::UntagResourceError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
1535 crate::operation::untag_resource::UntagResourceError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1536 crate::operation::untag_resource::UntagResourceError::ValidationException(inner) => Error::ValidationException(inner),
1537 crate::operation::untag_resource::UntagResourceError::Unhandled(inner) => Error::Unhandled(inner),
1538 }
1539 }
1540}
1541impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::update_engagement_context::UpdateEngagementContextError, R>>
1542 for Error
1543where
1544 R: Send + Sync + std::fmt::Debug + 'static,
1545{
1546 fn from(
1547 err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::update_engagement_context::UpdateEngagementContextError, R>,
1548 ) -> Self {
1549 match err {
1550 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1551 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1552 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1553 source: err.into(),
1554 }),
1555 }
1556 }
1557}
1558impl From<crate::operation::update_engagement_context::UpdateEngagementContextError> for Error {
1559 fn from(err: crate::operation::update_engagement_context::UpdateEngagementContextError) -> Self {
1560 match err {
1561 crate::operation::update_engagement_context::UpdateEngagementContextError::AccessDeniedException(inner) => {
1562 Error::AccessDeniedException(inner)
1563 }
1564 crate::operation::update_engagement_context::UpdateEngagementContextError::ConflictException(inner) => Error::ConflictException(inner),
1565 crate::operation::update_engagement_context::UpdateEngagementContextError::InternalServerException(inner) => {
1566 Error::InternalServerException(inner)
1567 }
1568 crate::operation::update_engagement_context::UpdateEngagementContextError::ResourceNotFoundException(inner) => {
1569 Error::ResourceNotFoundException(inner)
1570 }
1571 crate::operation::update_engagement_context::UpdateEngagementContextError::ServiceQuotaExceededException(inner) => {
1572 Error::ServiceQuotaExceededException(inner)
1573 }
1574 crate::operation::update_engagement_context::UpdateEngagementContextError::ThrottlingException(inner) => {
1575 Error::ThrottlingException(inner)
1576 }
1577 crate::operation::update_engagement_context::UpdateEngagementContextError::ValidationException(inner) => {
1578 Error::ValidationException(inner)
1579 }
1580 crate::operation::update_engagement_context::UpdateEngagementContextError::Unhandled(inner) => Error::Unhandled(inner),
1581 }
1582 }
1583}
1584impl<R> From<::aws_smithy_runtime_api::client::result::SdkError<crate::operation::update_opportunity::UpdateOpportunityError, R>> for Error
1585where
1586 R: Send + Sync + std::fmt::Debug + 'static,
1587{
1588 fn from(err: ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::update_opportunity::UpdateOpportunityError, R>) -> Self {
1589 match err {
1590 ::aws_smithy_runtime_api::client::result::SdkError::ServiceError(context) => Self::from(context.into_err()),
1591 _ => Error::Unhandled(crate::error::sealed_unhandled::Unhandled {
1592 meta: ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(&err).clone(),
1593 source: err.into(),
1594 }),
1595 }
1596 }
1597}
1598impl From<crate::operation::update_opportunity::UpdateOpportunityError> for Error {
1599 fn from(err: crate::operation::update_opportunity::UpdateOpportunityError) -> Self {
1600 match err {
1601 crate::operation::update_opportunity::UpdateOpportunityError::AccessDeniedException(inner) => Error::AccessDeniedException(inner),
1602 crate::operation::update_opportunity::UpdateOpportunityError::ConflictException(inner) => Error::ConflictException(inner),
1603 crate::operation::update_opportunity::UpdateOpportunityError::InternalServerException(inner) => Error::InternalServerException(inner),
1604 crate::operation::update_opportunity::UpdateOpportunityError::ResourceNotFoundException(inner) => Error::ResourceNotFoundException(inner),
1605 crate::operation::update_opportunity::UpdateOpportunityError::ThrottlingException(inner) => Error::ThrottlingException(inner),
1606 crate::operation::update_opportunity::UpdateOpportunityError::ValidationException(inner) => Error::ValidationException(inner),
1607 crate::operation::update_opportunity::UpdateOpportunityError::Unhandled(inner) => Error::Unhandled(inner),
1608 }
1609 }
1610}
1611impl ::std::error::Error for Error {
1612 fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
1613 match self {
1614 Error::AccessDeniedException(inner) => inner.source(),
1615 Error::ConflictException(inner) => inner.source(),
1616 Error::InternalServerException(inner) => inner.source(),
1617 Error::ResourceNotFoundException(inner) => inner.source(),
1618 Error::ServiceQuotaExceededException(inner) => inner.source(),
1619 Error::ThrottlingException(inner) => inner.source(),
1620 Error::ValidationException(inner) => inner.source(),
1621 Error::Unhandled(inner) => ::std::option::Option::Some(&*inner.source),
1622 }
1623 }
1624}
1625impl ::aws_types::request_id::RequestId for Error {
1626 fn request_id(&self) -> Option<&str> {
1627 match self {
1628 Self::AccessDeniedException(e) => e.request_id(),
1629 Self::ConflictException(e) => e.request_id(),
1630 Self::InternalServerException(e) => e.request_id(),
1631 Self::ResourceNotFoundException(e) => e.request_id(),
1632 Self::ServiceQuotaExceededException(e) => e.request_id(),
1633 Self::ThrottlingException(e) => e.request_id(),
1634 Self::ValidationException(e) => e.request_id(),
1635 Self::Unhandled(e) => e.meta.request_id(),
1636 }
1637 }
1638}