1#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
4#[non_exhaustive]
5pub struct SearchTables;
6impl SearchTables {
7 pub fn new() -> Self {
9 Self
10 }
11 pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema<'static> = crate::operation::search_tables::SearchTablesInput::SCHEMA;
13 pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema<'static> = crate::operation::search_tables::SearchTablesOutput::SCHEMA;
15 pub(crate) async fn orchestrate(
16 runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
17 input: crate::operation::search_tables::SearchTablesInput,
18 ) -> ::std::result::Result<
19 crate::operation::search_tables::SearchTablesOutput,
20 ::aws_smithy_runtime_api::client::result::SdkError<
21 crate::operation::search_tables::SearchTablesError,
22 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
23 >,
24 > {
25 let map_err = |err: ::aws_smithy_runtime_api::client::result::SdkError<
26 ::aws_smithy_runtime_api::client::interceptors::context::Error,
27 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
28 >| {
29 err.map_service_error(|err| {
30 err.downcast::<crate::operation::search_tables::SearchTablesError>()
31 .expect("correct error type")
32 })
33 };
34 let context = Self::orchestrate_with_stop_point(runtime_plugins, input, ::aws_smithy_runtime::client::orchestrator::StopPoint::None)
35 .await
36 .map_err(map_err)?;
37 let output = context.finalize().map_err(map_err)?;
38 ::std::result::Result::Ok(
39 output
40 .downcast::<crate::operation::search_tables::SearchTablesOutput>()
41 .expect("correct output type"),
42 )
43 }
44
45 pub(crate) async fn orchestrate_with_stop_point(
46 runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
47 input: crate::operation::search_tables::SearchTablesInput,
48 stop_point: ::aws_smithy_runtime::client::orchestrator::StopPoint,
49 ) -> ::std::result::Result<
50 ::aws_smithy_runtime_api::client::interceptors::context::InterceptorContext,
51 ::aws_smithy_runtime_api::client::result::SdkError<
52 ::aws_smithy_runtime_api::client::interceptors::context::Error,
53 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
54 >,
55 > {
56 let input = ::aws_smithy_runtime_api::client::interceptors::context::Input::erase(input);
57 use ::tracing::Instrument;
58 ::aws_smithy_runtime::client::orchestrator::invoke_with_stop_point("Glue", "SearchTables", input, runtime_plugins, stop_point)
59 .instrument(::tracing::debug_span!(
62 "Glue.SearchTables",
63 "rpc.service" = "Glue",
64 "rpc.method" = "SearchTables",
65 "sdk_invocation_id" = ::fastrand::u32(1_000_000..10_000_000),
66 "rpc.system" = "aws-api",
67 ))
68 .await
69 }
70
71 pub(crate) fn operation_runtime_plugins(
72 client_runtime_plugins: ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
73 client_config: &crate::config::Config,
74 config_override: ::std::option::Option<crate::config::Builder>,
75 ) -> ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins {
76 let mut runtime_plugins = client_runtime_plugins.with_operation_plugin(Self::new());
77
78 if let ::std::option::Option::Some(config_override) = config_override {
79 for plugin in config_override.runtime_plugins.iter().cloned() {
80 runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
81 }
82 runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
83 config_override,
84 client_config.config.clone(),
85 &client_config.runtime_components,
86 ));
87 }
88 runtime_plugins
89 }
90}
91pub(crate) mod error_registry {
100 pub(crate) static REGISTRY: ::std::sync::LazyLock<::aws_smithy_schema::registry::TypeRegistry> = ::std::sync::LazyLock::new(|| {
101 ::aws_smithy_schema::registry::TypeRegistry::builder()
102 .insert_error_shape(
103 crate::types::error::InternalServiceException::SCHEMA,
104 |d: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer| -> ::std::result::Result<::aws_smithy_types::type_erasure::TypeErasedBox, ::aws_smithy_schema::serde::SerdeError> {
105 ::std::result::Result::Ok(::aws_smithy_types::type_erasure::TypeErasedBox::new(crate::types::error::InternalServiceException::deserialize(d)?))
106 },
107 |d: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer| -> ::std::result::Result<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync>, ::aws_smithy_schema::serde::SerdeError> {
108 ::std::result::Result::Ok(::std::boxed::Box::new(crate::types::error::InternalServiceException::deserialize(d)?))
109 },
110 )
111.insert_error_shape(
112 crate::types::error::InvalidInputException::SCHEMA,
113 |d: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer| -> ::std::result::Result<::aws_smithy_types::type_erasure::TypeErasedBox, ::aws_smithy_schema::serde::SerdeError> {
114 ::std::result::Result::Ok(::aws_smithy_types::type_erasure::TypeErasedBox::new(crate::types::error::InvalidInputException::deserialize(d)?))
115 },
116 |d: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer| -> ::std::result::Result<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync>, ::aws_smithy_schema::serde::SerdeError> {
117 ::std::result::Result::Ok(::std::boxed::Box::new(crate::types::error::InvalidInputException::deserialize(d)?))
118 },
119 )
120.insert_error_shape(
121 crate::types::error::OperationTimeoutException::SCHEMA,
122 |d: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer| -> ::std::result::Result<::aws_smithy_types::type_erasure::TypeErasedBox, ::aws_smithy_schema::serde::SerdeError> {
123 ::std::result::Result::Ok(::aws_smithy_types::type_erasure::TypeErasedBox::new(crate::types::error::OperationTimeoutException::deserialize(d)?))
124 },
125 |d: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer| -> ::std::result::Result<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync>, ::aws_smithy_schema::serde::SerdeError> {
126 ::std::result::Result::Ok(::std::boxed::Box::new(crate::types::error::OperationTimeoutException::deserialize(d)?))
127 },
128 )
129 .build()
130 });
131}
132impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for SearchTables {
133 fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
134 let mut cfg = ::aws_smithy_types::config_bag::Layer::new("SearchTables");
135
136 cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
137 SearchTablesRequestSerializer,
138 ));
139 cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
140 SearchTablesResponseDeserializer,
141 ));
142
143 cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
144 crate::config::auth::Params::builder()
145 .operation_name("SearchTables")
146 .build()
147 .expect("required fields set"),
148 ));
149
150 cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new("SearchTables", "Glue"));
151 let mut signing_options = ::aws_runtime::auth::SigningOptions::default();
152 signing_options.double_uri_encode = true;
153 signing_options.content_sha256_header = false;
154 signing_options.normalize_uri_path = true;
155 signing_options.payload_override = None;
156
157 cfg.store_put(::aws_runtime::auth::SigV4OperationSigningConfig {
158 signing_options,
159 ..::std::default::Default::default()
160 });
161
162 ::std::option::Option::Some(cfg.freeze())
163 }
164
165 fn runtime_components(
166 &self,
167 _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
168 ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
169 #[allow(unused_mut)]
170 let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("SearchTables")
171 .with_interceptor(::aws_smithy_runtime_api::client::interceptors::SharedInterceptor::permanent(
172 SearchTablesTelemetryInputCaptureInterceptor,
173 ))
174 .with_interceptor(::aws_smithy_runtime_api::client::interceptors::SharedInterceptor::permanent(
175 ::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default(),
176 ))
177 .with_interceptor(::aws_smithy_runtime_api::client::interceptors::SharedInterceptor::permanent(
178 SearchTablesEndpointParamsInterceptor,
179 ))
180 .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
181 crate::operation::search_tables::SearchTablesError,
182 >::new())
183 .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
184 crate::operation::search_tables::SearchTablesError,
185 >::new())
186 .with_retry_classifier(::aws_runtime::retries::classifiers::AwsErrorCodeClassifier::<
187 crate::operation::search_tables::SearchTablesError,
188 >::new())
189 .with_retry_classifier(::aws_runtime::service_clock_skew::ServiceClockSkewClassifier::<
190 crate::operation::search_tables::SearchTablesError,
191 >::new());
192
193 ::std::borrow::Cow::Owned(rcb)
194 }
195}
196
197#[derive(Debug)]
198struct SearchTablesTelemetryInputCaptureInterceptor;
199
200#[::aws_smithy_runtime_api::client::interceptors::dyn_dispatch_hint]
201impl ::aws_smithy_runtime_api::client::interceptors::Intercept for SearchTablesTelemetryInputCaptureInterceptor {
202 fn name(&self) -> &'static str {
203 "SearchTablesTelemetryInputCaptureInterceptor"
204 }
205
206 fn read_before_execution(
207 &self,
208 context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
209 '_,
210 ::aws_smithy_runtime_api::client::interceptors::context::Input,
211 ::aws_smithy_runtime_api::client::interceptors::context::Output,
212 ::aws_smithy_runtime_api::client::interceptors::context::Error,
213 >,
214 cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
215 ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
216 let ::std::option::Option::Some(requested) = cfg
218 .load::<::aws_smithy_types::telemetry::RequestedTelemetryAttributes>()
219 .filter(|r| !r.is_empty())
220 else {
221 return ::std::result::Result::Ok(());
222 };
223
224 let ::std::option::Option::Some(input) = context.input().downcast_ref::<SearchTablesInput>() else {
225 return ::std::result::Result::Ok(());
227 };
228
229 let mut captured = ::aws_smithy_types::telemetry::CapturedTelemetryAttributes::default();
230 if requested.should_capture("CatalogId") {
231 if let ::std::option::Option::Some(value) = input.catalog_id.as_deref() {
232 captured.insert("CatalogId", value);
233 }
234 }
235 if requested.should_capture("NextToken") {
236 if let ::std::option::Option::Some(value) = input.next_token.as_deref() {
237 captured.insert("NextToken", value);
238 }
239 }
240 if requested.should_capture("SearchText") {
241 if let ::std::option::Option::Some(value) = input.search_text.as_deref() {
242 captured.insert("SearchText", value);
243 }
244 }
245
246 cfg.interceptor_state().store_put(captured);
247 ::std::result::Result::Ok(())
248 }
249}
250#[derive(Debug)]
251struct SearchTablesResponseDeserializer;
252impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for SearchTablesResponseDeserializer {
253 fn deserialize_nonstreaming_with_config(
254 &self,
255 response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
256 _cfg: &::aws_smithy_types::config_bag::ConfigBag,
257 ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
258 let (success, status) = (response.status().is_success(), response.status().as_u16());
259 #[allow(unused_variables)]
264 let body = response.body().bytes().expect("body loaded");
265 let headers = response.headers();
266 #[allow(unused_mut)]
267 let mut force_error = false;
268 ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
269 if !success && status != 200 || force_error {
270 let protocol = _cfg
271 .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
272 .expect("a SharedClientProtocol is required");
273 #[allow(unused_mut)]
274 let mut generic_builder = protocol.parse_error_metadata(response, _cfg).map_err(|e| {
275 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
276 })?;
277 generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
278 let generic = generic_builder.build();
279 let error_code = match generic.code() {
280 ::std::option::Option::Some(code) => code,
281 ::std::option::Option::None => {
282 return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
283 ::aws_smithy_runtime_api::box_error::BoxError::from(crate::operation::search_tables::SearchTablesError::unhandled(generic)),
284 ))
285 }
286 };
287 let _error_message = generic.message().map(|msg| msg.to_owned());
288 let err = match error_code {
289 "InternalServiceException" => crate::operation::search_tables::SearchTablesError::InternalServiceException({
290 let mut deser = protocol.deserialize_error_response(response, _cfg).map_err(|e| {
291 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(
292 e,
293 ))
294 })?;
295 let mut tmp = <crate::types::error::builders::InternalServiceExceptionBuilder>::default();
296 tmp.deserialize_members(&mut *deser).map_err(|e| {
297 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(
298 e,
299 ))
300 })?;
301 if tmp.message.is_none() {
302 tmp.message = _error_message;
303 }
304 let tmp = tmp.meta(generic);
305 tmp.build()
306 }),
307 "InvalidInputException" => crate::operation::search_tables::SearchTablesError::InvalidInputException({
308 let mut deser = protocol.deserialize_error_response(response, _cfg).map_err(|e| {
309 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(
310 e,
311 ))
312 })?;
313 let mut tmp = <crate::types::error::builders::InvalidInputExceptionBuilder>::default();
314 tmp.deserialize_members(&mut *deser).map_err(|e| {
315 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(
316 e,
317 ))
318 })?;
319 if tmp.message.is_none() {
320 tmp.message = _error_message;
321 }
322 let tmp = tmp.meta(generic);
323 tmp.build()
324 }),
325 "OperationTimeoutException" => crate::operation::search_tables::SearchTablesError::OperationTimeoutException({
326 let mut deser = protocol.deserialize_error_response(response, _cfg).map_err(|e| {
327 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(
328 e,
329 ))
330 })?;
331 let mut tmp = <crate::types::error::builders::OperationTimeoutExceptionBuilder>::default();
332 tmp.deserialize_members(&mut *deser).map_err(|e| {
333 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(
334 e,
335 ))
336 })?;
337 if tmp.message.is_none() {
338 tmp.message = _error_message;
339 }
340 let tmp = tmp.meta(generic);
341 tmp.build()
342 }),
343 _ => {
344 match protocol
352 .deserialize_error_response(response, _cfg)
353 .ok()
354 .and_then(|mut deser| {
355 ::aws_smithy_schema::registry::reify_error(
356 crate::operation::search_tables::error_registry::REGISTRY
357 .or(&crate::error_type_registry::REGISTRY),
358 error_code,
359 &mut *deser,
360 )
361 }) {
362 ::std::option::Option::Some(source) => <crate::operation::search_tables::SearchTablesError as ::aws_smithy_runtime_api::client::result::CreateUnhandledError>::create_unhandled_error(source, ::std::option::Option::Some(generic)),
363 ::std::option::Option::None => crate::operation::search_tables::SearchTablesError::generic(generic),
364 }
365 }
366 };
367 ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
368 ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
369 ))
370 } else {
371 let protocol = _cfg
372 .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
373 .expect("a SharedClientProtocol is required");
374 let mut deser = protocol.deserialize_response(response, SearchTables::OUTPUT_SCHEMA, _cfg).map_err(|e| {
375 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
376 })?;
377 let _response_headers = headers;
381 #[allow(unused_mut)]
385 let mut output = <crate::operation::search_tables::builders::SearchTablesOutputBuilder>::default();
386 output.deserialize_members(&mut *deser).map_err(|e| {
387 ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
388 })?;
389 output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
390 let output = output.build();
391 ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
392 }
393 }
394}
395#[derive(Debug)]
396struct SearchTablesRequestSerializer;
397impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for SearchTablesRequestSerializer {
398 #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
399 fn serialize_input(
400 &self,
401 input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
402 _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
403 ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
404 let input = input
405 .downcast::<crate::operation::search_tables::SearchTablesInput>()
406 .expect("correct type");
407
408 let protocol = _cfg
409 .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
410 .expect("a SharedClientProtocol is required");
411 let mut request = protocol
412 .serialize_request(&input, SearchTables::INPUT_SCHEMA, "/", _cfg)
413 .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
414
415 return ::std::result::Result::Ok(request);
416 }
417}
418#[derive(Debug)]
419struct SearchTablesEndpointParamsInterceptor;
420
421#[::aws_smithy_runtime_api::client::interceptors::dyn_dispatch_hint]
422impl ::aws_smithy_runtime_api::client::interceptors::Intercept for SearchTablesEndpointParamsInterceptor {
423 fn name(&self) -> &'static str {
424 "SearchTablesEndpointParamsInterceptor"
425 }
426
427 fn read_before_execution(
428 &self,
429 context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
430 '_,
431 ::aws_smithy_runtime_api::client::interceptors::context::Input,
432 ::aws_smithy_runtime_api::client::interceptors::context::Output,
433 ::aws_smithy_runtime_api::client::interceptors::context::Error,
434 >,
435 cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
436 ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
437 let _input = context
438 .input()
439 .downcast_ref::<SearchTablesInput>()
440 .ok_or("failed to downcast to SearchTablesInput")?;
441
442 let params = crate::config::endpoint::Params::builder()
443 .set_region(cfg.load::<::aws_types::region::Region>().map(|r| r.as_ref().to_owned()))
444 .set_use_dual_stack(cfg.load::<::aws_types::endpoint_config::UseDualStack>().map(|ty| ty.0))
445 .set_use_fips(cfg.load::<::aws_types::endpoint_config::UseFips>().map(|ty| ty.0))
446 .set_endpoint(cfg.load::<::aws_types::endpoint_config::EndpointUrl>().map(|ty| ty.0.clone()))
447 .build()
448 .map_err(|err| {
449 ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
450 })?;
451 cfg.interceptor_state()
452 .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
453 ::std::result::Result::Ok(())
454 }
455}
456
457#[non_exhaustive]
462#[derive(::std::fmt::Debug)]
463pub enum SearchTablesError {
464 InternalServiceException(crate::types::error::InternalServiceException),
466 InvalidInputException(crate::types::error::InvalidInputException),
468 OperationTimeoutException(crate::types::error::OperationTimeoutException),
470 #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
472 variable wildcard pattern and check `.code()`:
473 \
474 `err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
475 \
476 See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-SearchTablesError) for what information is available for the error.")]
477 Unhandled(crate::error::sealed_unhandled::Unhandled),
478}
479impl SearchTablesError {
480 pub fn unhandled(
482 err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
483 ) -> Self {
484 Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
485 source: err.into(),
486 meta: ::std::default::Default::default(),
487 })
488 }
489
490 pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
492 Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
493 source: err.clone().into(),
494 meta: err,
495 })
496 }
497 pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
502 match self {
503 Self::InternalServiceException(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
504 Self::InvalidInputException(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
505 Self::OperationTimeoutException(e) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(e),
506 Self::Unhandled(e) => &e.meta,
507 }
508 }
509 pub fn is_internal_service_exception(&self) -> bool {
511 matches!(self, Self::InternalServiceException(_))
512 }
513 pub fn is_invalid_input_exception(&self) -> bool {
515 matches!(self, Self::InvalidInputException(_))
516 }
517 pub fn is_operation_timeout_exception(&self) -> bool {
519 matches!(self, Self::OperationTimeoutException(_))
520 }
521}
522impl ::std::error::Error for SearchTablesError {
523 fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
524 match self {
525 Self::InternalServiceException(_inner) => ::std::option::Option::Some(_inner),
526 Self::InvalidInputException(_inner) => ::std::option::Option::Some(_inner),
527 Self::OperationTimeoutException(_inner) => ::std::option::Option::Some(_inner),
528 Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
529 }
530 }
531}
532impl ::std::fmt::Display for SearchTablesError {
533 fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
534 match self {
535 Self::InternalServiceException(_inner) => _inner.fmt(f),
536 Self::InvalidInputException(_inner) => _inner.fmt(f),
537 Self::OperationTimeoutException(_inner) => _inner.fmt(f),
538 Self::Unhandled(_inner) => {
539 if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
540 write!(f, "unhandled error ({code})")
541 } else {
542 f.write_str("unhandled error")
543 }
544 }
545 }
546 }
547}
548impl ::aws_smithy_types::retry::ProvideErrorKind for SearchTablesError {
549 fn code(&self) -> ::std::option::Option<&str> {
550 ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
551 }
552 fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
553 ::std::option::Option::None
554 }
555}
556impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for SearchTablesError {
557 fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
558 match self {
559 Self::InternalServiceException(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
560 Self::InvalidInputException(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
561 Self::OperationTimeoutException(_inner) => ::aws_smithy_types::error::metadata::ProvideErrorMetadata::meta(_inner),
562 Self::Unhandled(_inner) => &_inner.meta,
563 }
564 }
565}
566impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for SearchTablesError {
567 fn create_unhandled_error(
568 source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
569 meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
570 ) -> Self {
571 Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
572 source,
573 meta: meta.unwrap_or_default(),
574 })
575 }
576}
577impl ::aws_types::request_id::RequestId for crate::operation::search_tables::SearchTablesError {
578 fn request_id(&self) -> Option<&str> {
579 self.meta().request_id()
580 }
581}
582
583pub use crate::operation::search_tables::_search_tables_input::SearchTablesInput;
584
585pub use crate::operation::search_tables::_search_tables_output::SearchTablesOutput;
586
587mod _search_tables_input;
588
589mod _search_tables_output;
590
591pub mod builders;
593
594pub mod paginator;