235 235 | '_,
|
236 236 | ::aws_smithy_runtime_api::client::interceptors::context::Input,
|
237 237 | ::aws_smithy_runtime_api::client::interceptors::context::Output,
|
238 238 | ::aws_smithy_runtime_api::client::interceptors::context::Error,
|
239 239 | >,
|
240 240 | cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
|
241 241 | ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
|
242 242 | let _input = context
|
243 243 | .input()
|
244 244 | .downcast_ref::<PutJobTaggingInput>()
|
245 245 | .ok_or("failed to downcast to PutJobTaggingInput")?;
|
246 246 |
|
247 247 | let params = crate::config::endpoint::Params::builder()
|
248 248 | .set_region(cfg.load::<::aws_types::region::Region>().map(|r| r.as_ref().to_owned()))
|
249 249 | .set_use_fips(cfg.load::<::aws_types::endpoint_config::UseFips>().map(|ty| ty.0))
|
250 250 | .set_use_dual_stack(cfg.load::<::aws_types::endpoint_config::UseDualStack>().map(|ty| ty.0))
|
251 251 | .set_endpoint(cfg.load::<::aws_types::endpoint_config::EndpointUrl>().map(|ty| ty.0.clone()))
|
252 252 | .set_use_arn_region(cfg.load::<crate::config::UseArnRegion>().map(|ty| ty.0))
|
253 253 | .set_requires_account_id(Some(true))
|
254 254 | .set_account_id(Some(
|
255 255 | _input
|
256 256 | .account_id
|
257 257 | .clone()
|
258 258 | .filter(|f| !AsRef::<str>::as_ref(f).trim().is_empty())
|
259 259 | .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("account_id", "A required field was not set"))?,
|
260 260 | ))
|
261 261 | .build()
|
262 262 | .map_err(|err| {
|
263 263 | ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
|
264 264 | })?;
|
265 + |
|
265 266 | cfg.interceptor_state()
|
266 267 | .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
|
268 + |
|
267 269 | ::std::result::Result::Ok(())
|
268 270 | }
|
269 271 | }
|
270 272 |
|
271 273 | // The get_* functions below are generated from JMESPath expressions in the
|
272 274 | // operationContextParams trait. They target the operation's input shape.
|
273 275 |
|
274 276 | /// Error type for the `PutJobTaggingError` operation.
|
275 277 | #[non_exhaustive]
|
276 278 | #[derive(::std::fmt::Debug)]
|
277 279 | pub enum PutJobTaggingError {
|
278 280 | /// <p></p>
|
279 281 | InternalServiceException(crate::types::error::InternalServiceException),
|
280 282 | /// <p></p>
|
281 283 | NotFoundException(crate::types::error::NotFoundException),
|
282 284 | /// <p></p>
|
283 285 | TooManyRequestsException(crate::types::error::TooManyRequestsException),
|
284 286 | /// <p>Amazon S3 throws this exception if you have too many tags in your tag set.</p>
|
285 287 | TooManyTagsException(crate::types::error::TooManyTagsException),
|
286 288 | /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
|
287 289 | #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
|
288 290 | variable wildcard pattern and check `.code()`:
|
289 291 | \
|
290 292 | `err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
|
291 293 | \
|
292 294 | See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-PutJobTaggingError) for what information is available for the error.")]
|
293 295 | Unhandled(crate::error::sealed_unhandled::Unhandled),
|
294 296 | }
|
295 297 | impl PutJobTaggingError {
|
296 298 | /// Creates the `PutJobTaggingError::Unhandled` variant from any error type.
|