Client Test

Client Test

rev. dfb5149b65b7bcc09edd15b8e071ad43b5ac5943 (ignoring whitespace)

Files changed:

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/ignores_wrapping_xml_name/_ignores_wrapping_xml_name_output.rs

@@ -1,1 +47,88 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct IgnoresWrappingXmlNameOutput {
           8  +
pub /* StructureGenerator.kt:201 */ struct IgnoresWrappingXmlNameOutput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub foo: ::std::option::Option<::std::string::String>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl IgnoresWrappingXmlNameOutput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn foo(&self) -> ::std::option::Option<&str> {
          20  +
        /* StructureGenerator.kt:169 */
   12     21   
        self.foo.as_deref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl IgnoresWrappingXmlNameOutput {
   16         -
    /// Creates a new builder-style object to manufacture [`IgnoresWrappingXmlNameOutput`](crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`IgnoresWrappingXmlNameOutput`](crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::ignores_wrapping_xml_name::builders::IgnoresWrappingXmlNameOutputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::ignores_wrapping_xml_name::builders::IgnoresWrappingXmlNameOutputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`IgnoresWrappingXmlNameOutput`](crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`IgnoresWrappingXmlNameOutput`](crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput).
          39  +
/* RustType.kt:516 */
   23     40   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          41  +
/* RustType.kt:516 */
   24     42   
#[non_exhaustive]
          43  +
/* BuilderGenerator.kt:345 */
   25     44   
pub struct IgnoresWrappingXmlNameOutputBuilder {
   26         -
    pub(crate) foo: ::std::option::Option<::std::string::String>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) foo: ::std::option::Option<::std::string::String>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl IgnoresWrappingXmlNameOutputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
          52  +
                           /* BuilderGenerator.kt:291 */
   30     53   
    pub fn foo(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
          54  +
        /* BuilderGenerator.kt:292 */
   31     55   
        self.foo = ::std::option::Option::Some(input.into());
          56  +
        /* BuilderGenerator.kt:293 */
   32     57   
        self
          58  +
        /* BuilderGenerator.kt:291 */
   33     59   
    }
          60  +
    /* BuilderGenerator.kt:312 */
   34     61   
    #[allow(missing_docs)] // documentation missing in model
          62  +
                           /* BuilderGenerator.kt:314 */
   35     63   
    pub fn set_foo(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
          64  +
        /* BuilderGenerator.kt:315 */
   36     65   
        self.foo = input;
   37     66   
        self
          67  +
        /* BuilderGenerator.kt:314 */
   38     68   
    }
          69  +
    /* BuilderGenerator.kt:334 */
   39     70   
    #[allow(missing_docs)] // documentation missing in model
          71  +
                           /* BuilderGenerator.kt:336 */
   40     72   
    pub fn get_foo(&self) -> &::std::option::Option<::std::string::String> {
          73  +
        /* BuilderGenerator.kt:337 */
   41     74   
        &self.foo
          75  +
        /* BuilderGenerator.kt:336 */
   42     76   
    }
   43         -
    /// Consumes the builder and constructs a [`IgnoresWrappingXmlNameOutput`](crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput).
          77  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`IgnoresWrappingXmlNameOutput`](crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput).
          78  +
    /* BuilderGenerator.kt:253 */
   44     79   
    pub fn build(self) -> crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput {
   45         -
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput { foo: self.foo }
          80  +
        /* BuilderGenerator.kt:477 */
          81  +
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput {
          82  +
            /* BuilderGenerator.kt:481 */ foo: self.foo,
          83  +
            /* BuilderGenerator.kt:477 */
   46     84   
        }
          85  +
        /* BuilderGenerator.kt:253 */
          86  +
    }
          87  +
    /* BuilderGenerator.kt:355 */
   47     88   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/ignores_wrapping_xml_name/builders.rs

@@ -1,1 +111,123 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CodegenDelegator.kt:255 */
    2      3   
pub use crate::operation::ignores_wrapping_xml_name::_ignores_wrapping_xml_name_output::IgnoresWrappingXmlNameOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::ignores_wrapping_xml_name::_ignores_wrapping_xml_name_input::IgnoresWrappingXmlNameInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::ignores_wrapping_xml_name::builders::IgnoresWrappingXmlNameInputBuilder {
    7     10   
    /// Sends a request with this input using the given client.
    8     11   
    pub async fn send_with(
    9     12   
        self,
   10     13   
        client: &crate::Client,
   11     14   
    ) -> ::std::result::Result<
   12     15   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.ignores_wrapping_xml_name();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `IgnoresWrappingXmlName`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `IgnoresWrappingXmlName`.
   24     27   
///
   25         -
/// The xmlName trait on the output structure is ignored in AWS Query. The wrapping element is always operation name + "Response".
          28  +
/// /* FluentBuilderGenerator.kt:130 */The xmlName trait on the output structure is ignored in AWS Query. The wrapping element is always operation name + "Response".
          29  +
/* RustType.kt:516 */
   26     30   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          31  +
/* FluentBuilderGenerator.kt:270 */
   27     32   
pub struct IgnoresWrappingXmlNameFluentBuilder {
   28     33   
    handle: ::std::sync::Arc<crate::client::Handle>,
   29     34   
    inner: crate::operation::ignores_wrapping_xml_name::builders::IgnoresWrappingXmlNameInputBuilder,
   30     35   
    config_override: ::std::option::Option<crate::config::Builder>,
   31     36   
}
          37  +
/* FluentBuilderGenerator.kt:381 */
   32     38   
impl
   33     39   
    crate::client::customize::internal::CustomizableSend<
   34     40   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput,
   35     41   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameError,
   36     42   
    > for IgnoresWrappingXmlNameFluentBuilder
   37     43   
{
   38     44   
    fn send(
   39     45   
        self,
   40     46   
        config_override: crate::config::Builder,
   41     47   
    ) -> crate::client::customize::internal::BoxFuture<
   42     48   
        crate::client::customize::internal::SendResult<
   43     49   
            crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput,
   44     50   
            crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameError,
   45     51   
        >,
   46     52   
    > {
   47     53   
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
   48     54   
    }
   49     55   
}
          56  +
/* FluentBuilderGenerator.kt:282 */
   50     57   
impl IgnoresWrappingXmlNameFluentBuilder {
          58  +
    /* FluentBuilderGenerator.kt:288 */
   51     59   
    /// Creates a new `IgnoresWrappingXmlNameFluentBuilder`.
   52     60   
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
   53     61   
        Self {
   54     62   
            handle,
   55     63   
            inner: ::std::default::Default::default(),
   56     64   
            config_override: ::std::option::Option::None,
   57     65   
        }
   58     66   
    }
          67  +
    /* FluentBuilderGenerator.kt:301 */
   59     68   
    /// Access the IgnoresWrappingXmlName as a reference.
   60     69   
    pub fn as_input(&self) -> &crate::operation::ignores_wrapping_xml_name::builders::IgnoresWrappingXmlNameInputBuilder {
   61     70   
        &self.inner
   62     71   
    }
          72  +
    /* FluentBuilderGenerator.kt:145 */
   63     73   
    /// Sends the request and returns the response.
   64     74   
    ///
   65     75   
    /// If an error occurs, an `SdkError` will be returned with additional details that
   66     76   
    /// can be matched against.
   67     77   
    ///
   68     78   
    /// By default, any retryable failures will be retried twice. Retry behavior
   69     79   
    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
   70     80   
    /// set when configuring the client.
   71     81   
    pub async fn send(
   72     82   
        self,
   73     83   
    ) -> ::std::result::Result<
   74     84   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput,
   75     85   
        ::aws_smithy_runtime_api::client::result::SdkError<
   76     86   
            crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameError,
   77     87   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   78     88   
        >,
   79     89   
    > {
   80     90   
        let input = self
   81     91   
            .inner
   82     92   
            .build()
   83     93   
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
   84     94   
        let runtime_plugins = crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlName::operation_runtime_plugins(
   85     95   
            self.handle.runtime_plugins.clone(),
   86     96   
            &self.handle.conf,
   87     97   
            self.config_override,
   88     98   
        );
   89     99   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlName::orchestrate(&runtime_plugins, input).await
   90    100   
    }
   91    101   
   92    102   
    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
   93    103   
    pub fn customize(
   94    104   
        self,
   95    105   
    ) -> crate::client::customize::CustomizableOperation<
   96    106   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameOutput,
   97    107   
        crate::operation::ignores_wrapping_xml_name::IgnoresWrappingXmlNameError,
   98    108   
        Self,
   99    109   
    > {
  100    110   
        crate::client::customize::CustomizableOperation::new(self)
  101    111   
    }
         112  +
    /* FluentBuilderGenerator.kt:315 */
  102    113   
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
  103    114   
        self.set_config_override(::std::option::Option::Some(config_override.into()));
  104    115   
        self
  105    116   
    }
  106    117   
  107    118   
    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
  108    119   
        self.config_override = config_override;
  109    120   
        self
  110    121   
    }
         122  +
    /* FluentBuilderGenerator.kt:282 */
  111    123   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/nested_structures.rs

@@ -1,1 +40,49 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* OperationGenerator.kt:77 */
    2      3   
/// Orchestration and serialization glue logic for `NestedStructures`.
           4  +
/* RustType.kt:516 */
    3      5   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
           6  +
/* RustType.kt:516 */
    4      7   
#[non_exhaustive]
           8  +
/* OperationGenerator.kt:84 */
    5      9   
pub struct NestedStructures;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl NestedStructures {
    7         -
    /// Creates a new `NestedStructures`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `NestedStructures`
          13  +
    /* OperationGenerator.kt:87 */
    8     14   
    pub fn new() -> Self {
          15  +
        /* OperationGenerator.kt:88 */
    9     16   
        Self
          17  +
        /* OperationGenerator.kt:87 */
   10     18   
    }
          19  +
    /* OperationGenerator.kt:138 */
   11     20   
    pub(crate) async fn orchestrate(
   12     21   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     22   
        input: crate::operation::nested_structures::NestedStructuresInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::nested_structures::NestedStructuresOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::nested_structures::NestedStructuresError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -57,66 +377,453 @@
   77     86   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   78     87   
            }
   79     88   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   80     89   
                config_override,
   81     90   
                client_config.config.clone(),
   82     91   
                &client_config.runtime_components,
   83     92   
            ));
   84     93   
        }
   85     94   
        runtime_plugins
   86     95   
    }
          96  +
    /* OperationGenerator.kt:85 */
   87     97   
}
          98  +
/* OperationRuntimePluginGenerator.kt:55 */
   88     99   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for NestedStructures {
   89    100   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   90    101   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("NestedStructures");
   91    102   
   92    103   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   93    104   
            NestedStructuresRequestSerializer,
   94    105   
        ));
   95    106   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
   96    107   
            NestedStructuresResponseDeserializer,
   97    108   
        ));
   98    109   
   99    110   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  100    111   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  101    112   
        ));
  102    113   
  103    114   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  104    115   
            "NestedStructures",
  105    116   
            "EC2 Protocol",
  106    117   
        ));
  107    118   
  108    119   
        ::std::option::Option::Some(cfg.freeze())
  109    120   
    }
  110    121   
  111    122   
    fn runtime_components(
  112    123   
        &self,
  113    124   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  114    125   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  115    126   
        #[allow(unused_mut)]
  116    127   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("NestedStructures")
  117    128   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  118    129   
            .with_interceptor(NestedStructuresEndpointParamsInterceptor)
  119    130   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  120    131   
                crate::operation::nested_structures::NestedStructuresError,
  121    132   
            >::new())
  122    133   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  123    134   
                crate::operation::nested_structures::NestedStructuresError,
  124    135   
            >::new());
  125    136   
  126    137   
        ::std::borrow::Cow::Owned(rcb)
  127    138   
    }
  128    139   
}
  129    140   
         141  +
/* ResponseDeserializerGenerator.kt:64 */
  130    142   
#[derive(Debug)]
  131    143   
struct NestedStructuresResponseDeserializer;
  132    144   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for NestedStructuresResponseDeserializer {
  133    145   
    fn deserialize_nonstreaming(
  134    146   
        &self,
  135    147   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  136    148   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  137    149   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  138    150   
        let headers = response.headers();
  139    151   
        let body = response.body().bytes().expect("body loaded");
  140    152   
        #[allow(unused_mut)]
  141    153   
        let mut force_error = false;
  142    154   
  143    155   
        let parse_result = if !success && status != 200 || force_error {
  144    156   
            crate::protocol_serde::shape_nested_structures::de_nested_structures_http_error(status, headers, body)
  145    157   
        } else {
  146    158   
            crate::protocol_serde::shape_nested_structures::de_nested_structures_http_response(status, headers, body)
  147    159   
        };
  148    160   
        crate::protocol_serde::type_erase_result(parse_result)
  149    161   
    }
  150    162   
}
         163  +
/* RequestSerializerGenerator.kt:67 */
  151    164   
#[derive(Debug)]
  152    165   
struct NestedStructuresRequestSerializer;
  153    166   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for NestedStructuresRequestSerializer {
  154    167   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  155    168   
    fn serialize_input(
  156    169   
        &self,
  157    170   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  158    171   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  159    172   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  160    173   
        let input = input
  161    174   
            .downcast::<crate::operation::nested_structures::NestedStructuresInput>()
  162    175   
            .expect("correct type");
  163    176   
        let _header_serialization_settings = _cfg
  164    177   
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  165    178   
            .cloned()
  166    179   
            .unwrap_or_default();
  167    180   
        let mut request_builder = {
  168    181   
            fn uri_base(
  169    182   
                _input: &crate::operation::nested_structures::NestedStructuresInput,
  170    183   
                output: &mut ::std::string::String,
  171    184   
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  172    185   
                use ::std::fmt::Write as _;
  173    186   
                ::std::write!(output, "/").expect("formatting should succeed");
  174    187   
                ::std::result::Result::Ok(())
  175    188   
            }
  176    189   
            #[allow(clippy::unnecessary_wraps)]
  177    190   
            fn update_http_builder(
  178    191   
                input: &crate::operation::nested_structures::NestedStructuresInput,
  179    192   
                builder: ::http::request::Builder,
  180    193   
            ) -> ::std::result::Result<::http::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  181    194   
                let mut uri = ::std::string::String::new();
  182    195   
                uri_base(input, &mut uri)?;
  183    196   
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  184    197   
            }
  185    198   
            let mut builder = update_http_builder(&input, ::http::request::Builder::new())?;
  186    199   
            builder = _header_serialization_settings.set_default_header(builder, ::http::header::CONTENT_TYPE, "application/x-www-form-urlencoded");
  187    200   
            builder
  188    201   
        };
  189    202   
        let body = ::aws_smithy_types::body::SdkBody::from(
  190    203   
            crate::protocol_serde::shape_nested_structures_input::ser_nested_structures_input_input_input(&input)?,
  191    204   
        );
  192    205   
        if let Some(content_length) = body.content_length() {
  193    206   
            let content_length = content_length.to_string();
  194    207   
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http::header::CONTENT_LENGTH, &content_length);
  195    208   
        }
  196    209   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  197    210   
    }
  198    211   
}
         212  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  199    213   
#[derive(Debug)]
  200    214   
struct NestedStructuresEndpointParamsInterceptor;
  201    215   
  202    216   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for NestedStructuresEndpointParamsInterceptor {
  203    217   
    fn name(&self) -> &'static str {
  204    218   
        "NestedStructuresEndpointParamsInterceptor"
  205    219   
    }
  206    220   
  207    221   
    fn read_before_execution(
  208    222   
        &self,
  209    223   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  210    224   
            '_,
  211    225   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  212    226   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  213    227   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  214    228   
        >,
  215    229   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  216    230   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  217    231   
        let _input = context
  218    232   
            .input()
  219    233   
            .downcast_ref::<NestedStructuresInput>()
  220    234   
            .ok_or("failed to downcast to NestedStructuresInput")?;
  221    235   
  222    236   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  223    237   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  224    238   
        })?;
  225    239   
        cfg.interceptor_state()
  226    240   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  227    241   
        ::std::result::Result::Ok(())
  228    242   
    }
  229    243   
}
  230    244   
  231    245   
// The get_* functions below are generated from JMESPath expressions in the
  232    246   
// operationContextParams trait. They target the operation's input shape.
  233    247   
         248  +
/* RustType.kt:516 */
  234    249   
#[allow(unreachable_code, unused_variables)]
         250  +
/* RustType.kt:516 */
  235    251   
#[cfg(test)]
         252  +
/* ProtocolTestGenerator.kt:98 */
  236    253   
mod nested_structures_test {
  237    254   
  238    255   
    /// Serializes nested structures using dots
  239    256   
    /// Test ID: Ec2NestedStructures
  240    257   
    #[::tokio::test]
  241    258   
    #[::tracing_test::traced_test]
  242    259   
    async fn ec2_nested_structures_request() {
  243    260   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  244    261   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  245    262   
  246    263   
        let client = crate::Client::from_conf(config_builder.http_client(http_client).build());
  247    264   
        let result = client
  248    265   
            .nested_structures()
  249    266   
            .set_nested(::std::option::Option::Some(
  250    267   
                crate::types::StructArg::builder()
  251    268   
                    .set_string_arg(::std::option::Option::Some("foo".to_owned()))
  252    269   
                    .set_other_arg(::std::option::Option::Some(true))
  253    270   
                    .set_recursive_arg(::std::option::Option::Some(::std::boxed::Box::new(
  254    271   
                        crate::types::StructArg::builder()
  255    272   
                            .set_string_arg(::std::option::Option::Some("baz".to_owned()))
  256    273   
                            .build(),
  257    274   
                    )))
  258    275   
                    .build(),
  259    276   
            ))
  260    277   
            .send()
  261    278   
            .await;
  262    279   
        let _ = dbg!(result);
  263    280   
        let http_request = request_receiver.expect_request();
  264    281   
        let expected_headers = [("Content-Type", "application/x-www-form-urlencoded")];
  265    282   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(http_request.headers(), expected_headers));
  266    283   
        let required_headers = &["Content-Length"];
  267    284   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::require_headers(http_request.headers(), required_headers));
  268    285   
        let body = http_request.body().bytes().expect("body should be strict");
  269    286   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
  270    287   
            body,
  271    288   
            "Action=NestedStructures&Version=2020-01-08&Nested.StringArg=foo&Nested.OtherArg=true&Nested.RecursiveArg.StringArg=baz",
  272    289   
            ::aws_smithy_protocol_test::MediaType::from("application/x-www-form-urlencoded"),
  273    290   
        ));
  274    291   
        let uri: ::http::Uri = http_request.uri().parse().expect("invalid URI sent");
  275    292   
        ::pretty_assertions::assert_eq!(http_request.method(), "POST", "method was incorrect");
  276    293   
        ::pretty_assertions::assert_eq!(uri.path(), "/", "path was incorrect");
  277    294   
    }
         295  +
         296  +
    /* ProtocolTestGenerator.kt:98 */
  278    297   
}
  279    298   
         299  +
/* OperationErrorGenerator.kt:79 */
  280    300   
/// Error type for the `NestedStructuresError` operation.
         301  +
/* RustType.kt:516 */
  281    302   
#[non_exhaustive]
         303  +
/* RustType.kt:516 */
  282    304   
#[derive(::std::fmt::Debug)]
  283         -
pub enum NestedStructuresError {
         305  +
pub /* OperationErrorGenerator.kt:81 */ enum NestedStructuresError {
         306  +
    /* OperationErrorGenerator.kt:88 */
  284    307   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  285    308   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  286    309   
    variable wildcard pattern and check `.code()`:
  287    310   
     \
  288    311   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  289    312   
     \
  290    313   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-NestedStructuresError) for what information is available for the error.")]
  291    314   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         315  +
    /* OperationErrorGenerator.kt:81 */
  292    316   
}
         317  +
/* OperationErrorGenerator.kt:218 */
  293    318   
impl NestedStructuresError {
         319  +
    /* OperationErrorGenerator.kt:219 */
  294    320   
    /// Creates the `NestedStructuresError::Unhandled` variant from any error type.
  295    321   
    pub fn unhandled(
  296    322   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  297    323   
    ) -> Self {
  298    324   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  299    325   
            source: err.into(),
  300    326   
            meta: ::std::default::Default::default(),
  301    327   
        })
  302    328   
    }
  303    329   
  304    330   
    /// Creates the `NestedStructuresError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  305    331   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  306    332   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  307    333   
            source: err.clone().into(),
  308    334   
            meta: err,
  309    335   
        })
  310    336   
    }
  311         -
    ///
         337  +
    /// /* OperationErrorGenerator.kt:236 */
  312    338   
    /// Returns error metadata, which includes the error code, message,
  313    339   
    /// request ID, and potentially additional information.
  314    340   
    ///
         341  +
    /* OperationErrorGenerator.kt:242 */
  315    342   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         343  +
        /* OperationErrorGenerator.kt:243 */
  316    344   
        match self {
  317         -
            Self::Unhandled(e) => &e.meta,
         345  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         346  +
            /* OperationErrorGenerator.kt:243 */
  318    347   
        }
         348  +
        /* OperationErrorGenerator.kt:242 */
  319    349   
    }
         350  +
    /* OperationErrorGenerator.kt:218 */
  320    351   
}
         352  +
/* OperationErrorGenerator.kt:269 */
  321    353   
impl ::std::error::Error for NestedStructuresError {
         354  +
    /* OperationErrorGenerator.kt:270 */
  322    355   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         356  +
        /* OperationErrorGenerator.kt:318 */
  323    357   
        match self {
  324         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         358  +
            /* OperationErrorGenerator.kt:326 */
         359  +
            Self::Unhandled(_inner) => {
         360  +
                /* OperationErrorGenerator.kt:279 */
         361  +
                ::std::option::Option::Some(&*_inner.source)
         362  +
                /* OperationErrorGenerator.kt:326 */
         363  +
            } /* OperationErrorGenerator.kt:318 */
  325    364   
        }
         365  +
        /* OperationErrorGenerator.kt:270 */
  326    366   
    }
         367  +
    /* OperationErrorGenerator.kt:269 */
  327    368   
}
         369  +
/* OperationErrorGenerator.kt:133 */
  328    370   
impl ::std::fmt::Display for NestedStructuresError {
         371  +
    /* OperationErrorGenerator.kt:134 */
  329    372   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         373  +
        /* OperationErrorGenerator.kt:318 */
  330    374   
        match self {
         375  +
            /* OperationErrorGenerator.kt:326 */
  331    376   
            Self::Unhandled(_inner) => {
         377  +
                /* OperationErrorGenerator.kt:139 */
  332    378   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  333    379   
                    write!(f, "unhandled error ({code})")
  334    380   
                } else {
  335    381   
                    f.write_str("unhandled error")
  336    382   
                }
         383  +
                /* OperationErrorGenerator.kt:326 */
         384  +
            } /* OperationErrorGenerator.kt:318 */
  337    385   
        }
         386  +
        /* OperationErrorGenerator.kt:134 */
  338    387   
    }
  339         -
    }
         388  +
    /* OperationErrorGenerator.kt:133 */
  340    389   
}
         390  +
/* OperationErrorGenerator.kt:182 */
  341    391   
impl ::aws_smithy_types::retry::ProvideErrorKind for NestedStructuresError {
         392  +
    /* OperationErrorGenerator.kt:186 */
  342    393   
    fn code(&self) -> ::std::option::Option<&str> {
         394  +
        /* OperationErrorGenerator.kt:187 */
  343    395   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         396  +
        /* OperationErrorGenerator.kt:186 */
  344    397   
    }
         398  +
    /* OperationErrorGenerator.kt:190 */
  345    399   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         400  +
        /* OperationErrorGenerator.kt:197 */
  346    401   
        ::std::option::Option::None
         402  +
        /* OperationErrorGenerator.kt:190 */
  347    403   
    }
         404  +
    /* OperationErrorGenerator.kt:182 */
  348    405   
}
         406  +
/* OperationErrorGenerator.kt:163 */
  349    407   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for NestedStructuresError {
         408  +
    /* OperationErrorGenerator.kt:164 */
  350    409   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         410  +
        /* OperationErrorGenerator.kt:318 */
  351    411   
        match self {
  352         -
            Self::Unhandled(_inner) => &_inner.meta,
         412  +
            /* OperationErrorGenerator.kt:326 */
         413  +
            Self::Unhandled(_inner) => {
         414  +
                /* OperationErrorGenerator.kt:168 */
         415  +
                &_inner.meta
         416  +
                /* OperationErrorGenerator.kt:326 */
         417  +
            } /* OperationErrorGenerator.kt:318 */
  353    418   
        }
         419  +
        /* OperationErrorGenerator.kt:164 */
  354    420   
    }
         421  +
    /* OperationErrorGenerator.kt:163 */
  355    422   
}
         423  +
/* OperationErrorGenerator.kt:109 */
  356    424   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for NestedStructuresError {
         425  +
    /* OperationErrorGenerator.kt:110 */
  357    426   
    fn create_unhandled_error(
  358    427   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  359    428   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  360    429   
    ) -> Self {
         430  +
        /* OperationErrorGenerator.kt:121 */
  361    431   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  362    432   
            source,
  363    433   
            meta: meta.unwrap_or_default(),
  364    434   
        })
         435  +
        /* OperationErrorGenerator.kt:110 */
  365    436   
    }
         437  +
    /* OperationErrorGenerator.kt:109 */
  366    438   
}
  367    439   
         440  +
/* CodegenDelegator.kt:255 */
  368    441   
pub use crate::operation::nested_structures::_nested_structures_output::NestedStructuresOutput;
  369    442   
         443  +
/* CodegenDelegator.kt:255 */
  370    444   
pub use crate::operation::nested_structures::_nested_structures_input::NestedStructuresInput;
  371    445   
         446  +
/* RustModule.kt:172 */
  372    447   
mod _nested_structures_input;
  373    448   
         449  +
/* RustModule.kt:172 */
  374    450   
mod _nested_structures_output;
  375    451   
  376         -
/// Builders
         452  +
/// /* CodegenDelegator.kt:51 */Builders
  377    453   
pub mod builders;

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/nested_structures/_nested_structures_input.rs

@@ -1,1 +49,93 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct NestedStructuresInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct NestedStructuresInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub nested: ::std::option::Option<crate::types::StructArg>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl NestedStructuresInput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn nested(&self) -> ::std::option::Option<&crate::types::StructArg> {
          20  +
        /* StructureGenerator.kt:170 */
   12     21   
        self.nested.as_ref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl NestedStructuresInput {
   16         -
    /// Creates a new builder-style object to manufacture [`NestedStructuresInput`](crate::operation::nested_structures::NestedStructuresInput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`NestedStructuresInput`](crate::operation::nested_structures::NestedStructuresInput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::nested_structures::builders::NestedStructuresInputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::nested_structures::builders::NestedStructuresInputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`NestedStructuresInput`](crate::operation::nested_structures::NestedStructuresInput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`NestedStructuresInput`](crate::operation::nested_structures::NestedStructuresInput).
          39  +
/* RustType.kt:516 */
   23     40   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          41  +
/* RustType.kt:516 */
   24     42   
#[non_exhaustive]
          43  +
/* BuilderGenerator.kt:345 */
   25     44   
pub struct NestedStructuresInputBuilder {
   26         -
    pub(crate) nested: ::std::option::Option<crate::types::StructArg>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) nested: ::std::option::Option<crate::types::StructArg>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl NestedStructuresInputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
          52  +
                           /* BuilderGenerator.kt:291 */
   30     53   
    pub fn nested(mut self, input: crate::types::StructArg) -> Self {
          54  +
        /* BuilderGenerator.kt:292 */
   31     55   
        self.nested = ::std::option::Option::Some(input);
          56  +
        /* BuilderGenerator.kt:293 */
   32     57   
        self
          58  +
        /* BuilderGenerator.kt:291 */
   33     59   
    }
          60  +
    /* BuilderGenerator.kt:312 */
   34     61   
    #[allow(missing_docs)] // documentation missing in model
          62  +
                           /* BuilderGenerator.kt:314 */
   35     63   
    pub fn set_nested(mut self, input: ::std::option::Option<crate::types::StructArg>) -> Self {
          64  +
        /* BuilderGenerator.kt:315 */
   36     65   
        self.nested = input;
   37     66   
        self
          67  +
        /* BuilderGenerator.kt:314 */
   38     68   
    }
          69  +
    /* BuilderGenerator.kt:334 */
   39     70   
    #[allow(missing_docs)] // documentation missing in model
          71  +
                           /* BuilderGenerator.kt:336 */
   40     72   
    pub fn get_nested(&self) -> &::std::option::Option<crate::types::StructArg> {
          73  +
        /* BuilderGenerator.kt:337 */
   41     74   
        &self.nested
          75  +
        /* BuilderGenerator.kt:336 */
   42     76   
    }
   43         -
    /// Consumes the builder and constructs a [`NestedStructuresInput`](crate::operation::nested_structures::NestedStructuresInput).
          77  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`NestedStructuresInput`](crate::operation::nested_structures::NestedStructuresInput).
          78  +
    /* BuilderGenerator.kt:253 */
   44     79   
    pub fn build(
   45     80   
        self,
   46     81   
    ) -> ::std::result::Result<crate::operation::nested_structures::NestedStructuresInput, ::aws_smithy_types::error::operation::BuildError> {
   47         -
        ::std::result::Result::Ok(crate::operation::nested_structures::NestedStructuresInput { nested: self.nested })
          82  +
        /* BuilderGenerator.kt:254 */
          83  +
        ::std::result::Result::Ok(
          84  +
            /* BuilderGenerator.kt:477 */
          85  +
            crate::operation::nested_structures::NestedStructuresInput {
          86  +
                /* BuilderGenerator.kt:481 */ nested: self.nested,
          87  +
                /* BuilderGenerator.kt:477 */
          88  +
            }, /* BuilderGenerator.kt:254 */
          89  +
        )
          90  +
        /* BuilderGenerator.kt:253 */
   48     91   
    }
          92  +
    /* BuilderGenerator.kt:355 */
   49     93   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/nested_structures/_nested_structures_output.rs

@@ -1,1 +22,39 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct NestedStructuresOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct NestedStructuresOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl NestedStructuresOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`NestedStructuresOutput`](crate::operation::nested_structures::NestedStructuresOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`NestedStructuresOutput`](crate::operation::nested_structures::NestedStructuresOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::nested_structures::builders::NestedStructuresOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::nested_structures::builders::NestedStructuresOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`NestedStructuresOutput`](crate::operation::nested_structures::NestedStructuresOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`NestedStructuresOutput`](crate::operation::nested_structures::NestedStructuresOutput).
          22  +
/* RustType.kt:516 */
   14     23   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          24  +
/* RustType.kt:516 */
   15     25   
#[non_exhaustive]
   16         -
pub struct NestedStructuresOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct NestedStructuresOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl NestedStructuresOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`NestedStructuresOutput`](crate::operation::nested_structures::NestedStructuresOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`NestedStructuresOutput`](crate::operation::nested_structures::NestedStructuresOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::nested_structures::NestedStructuresOutput {
   20         -
        crate::operation::nested_structures::NestedStructuresOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::nested_structures::NestedStructuresOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/nested_structures/builders.rs

@@ -1,1 +125,143 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CodegenDelegator.kt:255 */
    2      3   
pub use crate::operation::nested_structures::_nested_structures_output::NestedStructuresOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::nested_structures::_nested_structures_input::NestedStructuresInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::nested_structures::builders::NestedStructuresInputBuilder {
    7     10   
    /// Sends a request with this input using the given client.
    8     11   
    pub async fn send_with(
    9     12   
        self,
   10     13   
        client: &crate::Client,
   11     14   
    ) -> ::std::result::Result<
   12     15   
        crate::operation::nested_structures::NestedStructuresOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::nested_structures::NestedStructuresError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.nested_structures();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `NestedStructures`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `NestedStructures`.
   24     27   
///
   25         -
/// This test serializes nested and recursive structure members.
          28  +
/// /* FluentBuilderGenerator.kt:130 */This test serializes nested and recursive structure members.
          29  +
/* RustType.kt:516 */
   26     30   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          31  +
/* FluentBuilderGenerator.kt:270 */
   27     32   
pub struct NestedStructuresFluentBuilder {
   28     33   
    handle: ::std::sync::Arc<crate::client::Handle>,
   29     34   
    inner: crate::operation::nested_structures::builders::NestedStructuresInputBuilder,
   30     35   
    config_override: ::std::option::Option<crate::config::Builder>,
   31     36   
}
          37  +
/* FluentBuilderGenerator.kt:381 */
   32     38   
impl
   33     39   
    crate::client::customize::internal::CustomizableSend<
   34     40   
        crate::operation::nested_structures::NestedStructuresOutput,
   35     41   
        crate::operation::nested_structures::NestedStructuresError,
   36     42   
    > for NestedStructuresFluentBuilder
   37     43   
{
   38     44   
    fn send(
   39     45   
        self,
   40     46   
        config_override: crate::config::Builder,
   41     47   
    ) -> crate::client::customize::internal::BoxFuture<
   42     48   
        crate::client::customize::internal::SendResult<
   43     49   
            crate::operation::nested_structures::NestedStructuresOutput,
   44     50   
            crate::operation::nested_structures::NestedStructuresError,
   45     51   
        >,
   46     52   
    > {
   47     53   
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
   48     54   
    }
   49     55   
}
          56  +
/* FluentBuilderGenerator.kt:282 */
   50     57   
impl NestedStructuresFluentBuilder {
          58  +
    /* FluentBuilderGenerator.kt:288 */
   51     59   
    /// Creates a new `NestedStructuresFluentBuilder`.
   52     60   
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
   53     61   
        Self {
   54     62   
            handle,
   55     63   
            inner: ::std::default::Default::default(),
   56     64   
            config_override: ::std::option::Option::None,
   57     65   
        }
   58     66   
    }
          67  +
    /* FluentBuilderGenerator.kt:301 */
   59     68   
    /// Access the NestedStructures as a reference.
   60     69   
    pub fn as_input(&self) -> &crate::operation::nested_structures::builders::NestedStructuresInputBuilder {
   61     70   
        &self.inner
   62     71   
    }
          72  +
    /* FluentBuilderGenerator.kt:145 */
   63     73   
    /// Sends the request and returns the response.
   64     74   
    ///
   65     75   
    /// If an error occurs, an `SdkError` will be returned with additional details that
   66     76   
    /// can be matched against.
   67     77   
    ///
   68     78   
    /// By default, any retryable failures will be retried twice. Retry behavior
   69     79   
    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
   70     80   
    /// set when configuring the client.
   71     81   
    pub async fn send(
   72     82   
        self,
   73     83   
    ) -> ::std::result::Result<
   74     84   
        crate::operation::nested_structures::NestedStructuresOutput,
   75     85   
        ::aws_smithy_runtime_api::client::result::SdkError<
   76     86   
            crate::operation::nested_structures::NestedStructuresError,
   77     87   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   78     88   
        >,
   79     89   
    > {
   80     90   
        let input = self
   81     91   
            .inner
   82     92   
            .build()
   83     93   
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
   84     94   
        let runtime_plugins = crate::operation::nested_structures::NestedStructures::operation_runtime_plugins(
   85     95   
            self.handle.runtime_plugins.clone(),
   86     96   
            &self.handle.conf,
   87     97   
            self.config_override,
   88     98   
        );
   89     99   
        crate::operation::nested_structures::NestedStructures::orchestrate(&runtime_plugins, input).await
   90    100   
    }
   91    101   
   92    102   
    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
   93    103   
    pub fn customize(
   94    104   
        self,
   95    105   
    ) -> crate::client::customize::CustomizableOperation<
   96    106   
        crate::operation::nested_structures::NestedStructuresOutput,
   97    107   
        crate::operation::nested_structures::NestedStructuresError,
   98    108   
        Self,
   99    109   
    > {
  100    110   
        crate::client::customize::CustomizableOperation::new(self)
  101    111   
    }
         112  +
    /* FluentBuilderGenerator.kt:315 */
  102    113   
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
  103    114   
        self.set_config_override(::std::option::Option::Some(config_override.into()));
  104    115   
        self
  105    116   
    }
  106    117   
  107    118   
    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
  108    119   
        self.config_override = config_override;
  109    120   
        self
  110    121   
    }
         122  +
    /* FluentBuilderGenerator.kt:498 */
  111    123   
    #[allow(missing_docs)] // documentation missing in model
         124  +
                           /* FluentBuilderGenerator.kt:500 */
  112    125   
    pub fn nested(mut self, input: crate::types::StructArg) -> Self {
  113    126   
        self.inner = self.inner.nested(input);
  114    127   
        self
  115    128   
    }
         129  +
    /* FluentBuilderGenerator.kt:498 */
  116    130   
    #[allow(missing_docs)] // documentation missing in model
         131  +
                           /* FluentBuilderGenerator.kt:500 */
  117    132   
    pub fn set_nested(mut self, input: ::std::option::Option<crate::types::StructArg>) -> Self {
  118    133   
        self.inner = self.inner.set_nested(input);
  119    134   
        self
  120    135   
    }
         136  +
    /* FluentBuilderGenerator.kt:518 */
  121    137   
    #[allow(missing_docs)] // documentation missing in model
         138  +
                           /* FluentBuilderGenerator.kt:520 */
  122    139   
    pub fn get_nested(&self) -> &::std::option::Option<crate::types::StructArg> {
  123    140   
        self.inner.get_nested()
  124    141   
    }
         142  +
    /* FluentBuilderGenerator.kt:282 */
  125    143   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/no_input_and_output.rs

@@ -1,1 +40,49 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* OperationGenerator.kt:77 */
    2      3   
/// Orchestration and serialization glue logic for `NoInputAndOutput`.
           4  +
/* RustType.kt:516 */
    3      5   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
           6  +
/* RustType.kt:516 */
    4      7   
#[non_exhaustive]
           8  +
/* OperationGenerator.kt:84 */
    5      9   
pub struct NoInputAndOutput;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl NoInputAndOutput {
    7         -
    /// Creates a new `NoInputAndOutput`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `NoInputAndOutput`
          13  +
    /* OperationGenerator.kt:87 */
    8     14   
    pub fn new() -> Self {
          15  +
        /* OperationGenerator.kt:88 */
    9     16   
        Self
          17  +
        /* OperationGenerator.kt:87 */
   10     18   
    }
          19  +
    /* OperationGenerator.kt:138 */
   11     20   
    pub(crate) async fn orchestrate(
   12     21   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     22   
        input: crate::operation::no_input_and_output::NoInputAndOutputInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::no_input_and_output::NoInputAndOutputOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::no_input_and_output::NoInputAndOutputError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -57,66 +262,279 @@
   77     86   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   78     87   
            }
   79     88   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   80     89   
                config_override,
   81     90   
                client_config.config.clone(),
   82     91   
                &client_config.runtime_components,
   83     92   
            ));
   84     93   
        }
   85     94   
        runtime_plugins
   86     95   
    }
          96  +
    /* OperationGenerator.kt:85 */
   87     97   
}
          98  +
/* OperationRuntimePluginGenerator.kt:55 */
   88     99   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for NoInputAndOutput {
   89    100   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   90    101   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("NoInputAndOutput");
   91    102   
   92    103   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   93    104   
            NoInputAndOutputRequestSerializer,
   94    105   
        ));
   95    106   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
   96    107   
            NoInputAndOutputResponseDeserializer,
   97    108   
        ));
   98    109   
   99    110   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  100    111   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  101    112   
        ));
  102    113   
  103    114   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  104    115   
            "NoInputAndOutput",
  105    116   
            "EC2 Protocol",
  106    117   
        ));
  107    118   
  108    119   
        ::std::option::Option::Some(cfg.freeze())
  109    120   
    }
  110    121   
  111    122   
    fn runtime_components(
  112    123   
        &self,
  113    124   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  114    125   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  115    126   
        #[allow(unused_mut)]
  116    127   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("NoInputAndOutput")
  117    128   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  118    129   
            .with_interceptor(NoInputAndOutputEndpointParamsInterceptor)
  119    130   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  120    131   
                crate::operation::no_input_and_output::NoInputAndOutputError,
  121    132   
            >::new())
  122    133   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  123    134   
                crate::operation::no_input_and_output::NoInputAndOutputError,
  124    135   
            >::new());
  125    136   
  126    137   
        ::std::borrow::Cow::Owned(rcb)
  127    138   
    }
  128    139   
}
  129    140   
         141  +
/* ResponseDeserializerGenerator.kt:64 */
  130    142   
#[derive(Debug)]
  131    143   
struct NoInputAndOutputResponseDeserializer;
  132    144   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for NoInputAndOutputResponseDeserializer {
  133    145   
    fn deserialize_nonstreaming(
  134    146   
        &self,
  135    147   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  136    148   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  137    149   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  138    150   
        let headers = response.headers();
  139    151   
        let body = response.body().bytes().expect("body loaded");
  140    152   
        #[allow(unused_mut)]
  141    153   
        let mut force_error = false;
  142    154   
  143    155   
        let parse_result = if !success && status != 200 || force_error {
  144    156   
            crate::protocol_serde::shape_no_input_and_output::de_no_input_and_output_http_error(status, headers, body)
  145    157   
        } else {
  146    158   
            crate::protocol_serde::shape_no_input_and_output::de_no_input_and_output_http_response(status, headers, body)
  147    159   
        };
  148    160   
        crate::protocol_serde::type_erase_result(parse_result)
  149    161   
    }
  150    162   
}
         163  +
/* RequestSerializerGenerator.kt:67 */
  151    164   
#[derive(Debug)]
  152    165   
struct NoInputAndOutputRequestSerializer;
  153    166   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for NoInputAndOutputRequestSerializer {
  154    167   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  155    168   
    fn serialize_input(
  156    169   
        &self,
  157    170   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  158    171   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  159    172   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  160    173   
        let input = input
  161    174   
            .downcast::<crate::operation::no_input_and_output::NoInputAndOutputInput>()
  162    175   
            .expect("correct type");
  163    176   
        let _header_serialization_settings = _cfg
  164    177   
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  165    178   
            .cloned()
  166    179   
            .unwrap_or_default();
  167    180   
        let mut request_builder = {
  168    181   
            fn uri_base(
  169    182   
                _input: &crate::operation::no_input_and_output::NoInputAndOutputInput,
  170    183   
                output: &mut ::std::string::String,
  171    184   
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  172    185   
                use ::std::fmt::Write as _;
  173    186   
                ::std::write!(output, "/").expect("formatting should succeed");
  174    187   
                ::std::result::Result::Ok(())
  175    188   
            }
  176    189   
            #[allow(clippy::unnecessary_wraps)]
  177    190   
            fn update_http_builder(
  178    191   
                input: &crate::operation::no_input_and_output::NoInputAndOutputInput,
  179    192   
                builder: ::http::request::Builder,
  180    193   
            ) -> ::std::result::Result<::http::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  181    194   
                let mut uri = ::std::string::String::new();
  182    195   
                uri_base(input, &mut uri)?;
  183    196   
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  184    197   
            }
  185    198   
            let mut builder = update_http_builder(&input, ::http::request::Builder::new())?;
  186    199   
            builder = _header_serialization_settings.set_default_header(builder, ::http::header::CONTENT_TYPE, "application/x-www-form-urlencoded");
  187    200   
            builder
  188    201   
        };
  189    202   
        let body = ::aws_smithy_types::body::SdkBody::from(
  190    203   
            crate::protocol_serde::shape_no_input_and_output_input::ser_no_input_and_output_input_input_input(&input)?,
  191    204   
        );
  192    205   
  193    206   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  194    207   
    }
  195    208   
}
         209  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  196    210   
#[derive(Debug)]
  197    211   
struct NoInputAndOutputEndpointParamsInterceptor;
  198    212   
  199    213   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for NoInputAndOutputEndpointParamsInterceptor {
  200    214   
    fn name(&self) -> &'static str {
  201    215   
        "NoInputAndOutputEndpointParamsInterceptor"
  202    216   
    }
  203    217   
  204    218   
    fn read_before_execution(
  205    219   
        &self,
  206    220   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  207    221   
            '_,
  208    222   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  209    223   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  210    224   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  211    225   
        >,
  212    226   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  213    227   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  214    228   
        let _input = context
  215    229   
            .input()
  216    230   
            .downcast_ref::<NoInputAndOutputInput>()
  217    231   
            .ok_or("failed to downcast to NoInputAndOutputInput")?;
  218    232   
  219    233   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  220    234   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  221    235   
        })?;
  222    236   
        cfg.interceptor_state()
  223    237   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  224    238   
        ::std::result::Result::Ok(())
  225    239   
    }
  226    240   
}
  227    241   
  228    242   
// The get_* functions below are generated from JMESPath expressions in the
  229    243   
// operationContextParams trait. They target the operation's input shape.
  230    244   
         245  +
/* RustType.kt:516 */
  231    246   
#[allow(unreachable_code, unused_variables)]
         247  +
/* RustType.kt:516 */
  232    248   
#[cfg(test)]
         249  +
/* ProtocolTestGenerator.kt:98 */
  233    250   
mod no_input_and_output_test {
  234    251   
  235    252   
    /// No input serializes no payload
  236    253   
    /// Test ID: Ec2QueryNoInputAndOutput
  237    254   
    #[::tokio::test]
  238    255   
    #[::tracing_test::traced_test]
  239    256   
    async fn ec2_query_no_input_and_output_request() {
  240    257   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  241    258   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  242    259   
@@ -270,287 +399,475 @@
  290    307   
                    ::aws_smithy_protocol_test::MediaType::from("application/xml"),
  291    308   
                )))
  292    309   
            });
  293    310   
            de.deserialize_nonstreaming(&http_response)
  294    311   
        });
  295    312   
        let parsed = parsed
  296    313   
            .expect("should be successful response")
  297    314   
            .downcast::<crate::operation::no_input_and_output::NoInputAndOutputOutput>()
  298    315   
            .unwrap();
  299    316   
    }
         317  +
         318  +
    /* ProtocolTestGenerator.kt:98 */
  300    319   
}
  301    320   
         321  +
/* OperationErrorGenerator.kt:79 */
  302    322   
/// Error type for the `NoInputAndOutputError` operation.
         323  +
/* RustType.kt:516 */
  303    324   
#[non_exhaustive]
         325  +
/* RustType.kt:516 */
  304    326   
#[derive(::std::fmt::Debug)]
  305         -
pub enum NoInputAndOutputError {
         327  +
pub /* OperationErrorGenerator.kt:81 */ enum NoInputAndOutputError {
         328  +
    /* OperationErrorGenerator.kt:88 */
  306    329   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  307    330   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  308    331   
    variable wildcard pattern and check `.code()`:
  309    332   
     \
  310    333   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  311    334   
     \
  312    335   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-NoInputAndOutputError) for what information is available for the error.")]
  313    336   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         337  +
    /* OperationErrorGenerator.kt:81 */
  314    338   
}
         339  +
/* OperationErrorGenerator.kt:218 */
  315    340   
impl NoInputAndOutputError {
         341  +
    /* OperationErrorGenerator.kt:219 */
  316    342   
    /// Creates the `NoInputAndOutputError::Unhandled` variant from any error type.
  317    343   
    pub fn unhandled(
  318    344   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  319    345   
    ) -> Self {
  320    346   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  321    347   
            source: err.into(),
  322    348   
            meta: ::std::default::Default::default(),
  323    349   
        })
  324    350   
    }
  325    351   
  326    352   
    /// Creates the `NoInputAndOutputError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  327    353   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  328    354   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  329    355   
            source: err.clone().into(),
  330    356   
            meta: err,
  331    357   
        })
  332    358   
    }
  333         -
    ///
         359  +
    /// /* OperationErrorGenerator.kt:236 */
  334    360   
    /// Returns error metadata, which includes the error code, message,
  335    361   
    /// request ID, and potentially additional information.
  336    362   
    ///
         363  +
    /* OperationErrorGenerator.kt:242 */
  337    364   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         365  +
        /* OperationErrorGenerator.kt:243 */
  338    366   
        match self {
  339         -
            Self::Unhandled(e) => &e.meta,
         367  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         368  +
            /* OperationErrorGenerator.kt:243 */
  340    369   
        }
         370  +
        /* OperationErrorGenerator.kt:242 */
  341    371   
    }
         372  +
    /* OperationErrorGenerator.kt:218 */
  342    373   
}
         374  +
/* OperationErrorGenerator.kt:269 */
  343    375   
impl ::std::error::Error for NoInputAndOutputError {
         376  +
    /* OperationErrorGenerator.kt:270 */
  344    377   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         378  +
        /* OperationErrorGenerator.kt:318 */
  345    379   
        match self {
  346         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         380  +
            /* OperationErrorGenerator.kt:326 */
         381  +
            Self::Unhandled(_inner) => {
         382  +
                /* OperationErrorGenerator.kt:279 */
         383  +
                ::std::option::Option::Some(&*_inner.source)
         384  +
                /* OperationErrorGenerator.kt:326 */
         385  +
            } /* OperationErrorGenerator.kt:318 */
  347    386   
        }
         387  +
        /* OperationErrorGenerator.kt:270 */
  348    388   
    }
         389  +
    /* OperationErrorGenerator.kt:269 */
  349    390   
}
         391  +
/* OperationErrorGenerator.kt:133 */
  350    392   
impl ::std::fmt::Display for NoInputAndOutputError {
         393  +
    /* OperationErrorGenerator.kt:134 */
  351    394   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         395  +
        /* OperationErrorGenerator.kt:318 */
  352    396   
        match self {
         397  +
            /* OperationErrorGenerator.kt:326 */
  353    398   
            Self::Unhandled(_inner) => {
         399  +
                /* OperationErrorGenerator.kt:139 */
  354    400   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  355    401   
                    write!(f, "unhandled error ({code})")
  356    402   
                } else {
  357    403   
                    f.write_str("unhandled error")
  358    404   
                }
         405  +
                /* OperationErrorGenerator.kt:326 */
         406  +
            } /* OperationErrorGenerator.kt:318 */
  359    407   
        }
         408  +
        /* OperationErrorGenerator.kt:134 */
  360    409   
    }
  361         -
    }
         410  +
    /* OperationErrorGenerator.kt:133 */
  362    411   
}
         412  +
/* OperationErrorGenerator.kt:182 */
  363    413   
impl ::aws_smithy_types::retry::ProvideErrorKind for NoInputAndOutputError {
         414  +
    /* OperationErrorGenerator.kt:186 */
  364    415   
    fn code(&self) -> ::std::option::Option<&str> {
         416  +
        /* OperationErrorGenerator.kt:187 */
  365    417   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         418  +
        /* OperationErrorGenerator.kt:186 */
  366    419   
    }
         420  +
    /* OperationErrorGenerator.kt:190 */
  367    421   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         422  +
        /* OperationErrorGenerator.kt:197 */
  368    423   
        ::std::option::Option::None
         424  +
        /* OperationErrorGenerator.kt:190 */
  369    425   
    }
         426  +
    /* OperationErrorGenerator.kt:182 */
  370    427   
}
         428  +
/* OperationErrorGenerator.kt:163 */
  371    429   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for NoInputAndOutputError {
         430  +
    /* OperationErrorGenerator.kt:164 */
  372    431   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         432  +
        /* OperationErrorGenerator.kt:318 */
  373    433   
        match self {
  374         -
            Self::Unhandled(_inner) => &_inner.meta,
         434  +
            /* OperationErrorGenerator.kt:326 */
         435  +
            Self::Unhandled(_inner) => {
         436  +
                /* OperationErrorGenerator.kt:168 */
         437  +
                &_inner.meta
         438  +
                /* OperationErrorGenerator.kt:326 */
         439  +
            } /* OperationErrorGenerator.kt:318 */
  375    440   
        }
         441  +
        /* OperationErrorGenerator.kt:164 */
  376    442   
    }
         443  +
    /* OperationErrorGenerator.kt:163 */
  377    444   
}
         445  +
/* OperationErrorGenerator.kt:109 */
  378    446   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for NoInputAndOutputError {
         447  +
    /* OperationErrorGenerator.kt:110 */
  379    448   
    fn create_unhandled_error(
  380    449   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  381    450   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  382    451   
    ) -> Self {
         452  +
        /* OperationErrorGenerator.kt:121 */
  383    453   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  384    454   
            source,
  385    455   
            meta: meta.unwrap_or_default(),
  386    456   
        })
         457  +
        /* OperationErrorGenerator.kt:110 */
  387    458   
    }
         459  +
    /* OperationErrorGenerator.kt:109 */
  388    460   
}
  389    461   
         462  +
/* CodegenDelegator.kt:255 */
  390    463   
pub use crate::operation::no_input_and_output::_no_input_and_output_output::NoInputAndOutputOutput;
  391    464   
         465  +
/* CodegenDelegator.kt:255 */
  392    466   
pub use crate::operation::no_input_and_output::_no_input_and_output_input::NoInputAndOutputInput;
  393    467   
         468  +
/* RustModule.kt:172 */
  394    469   
mod _no_input_and_output_input;
  395    470   
         471  +
/* RustModule.kt:172 */
  396    472   
mod _no_input_and_output_output;
  397    473   
  398         -
/// Builders
         474  +
/// /* CodegenDelegator.kt:51 */Builders
  399    475   
pub mod builders;

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/no_input_and_output/_no_input_and_output_input.rs

@@ -1,1 +24,44 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct NoInputAndOutputInput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct NoInputAndOutputInput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl NoInputAndOutputInput {
    7         -
    /// Creates a new builder-style object to manufacture [`NoInputAndOutputInput`](crate::operation::no_input_and_output::NoInputAndOutputInput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`NoInputAndOutputInput`](crate::operation::no_input_and_output::NoInputAndOutputInput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::no_input_and_output::builders::NoInputAndOutputInputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::no_input_and_output::builders::NoInputAndOutputInputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`NoInputAndOutputInput`](crate::operation::no_input_and_output::NoInputAndOutputInput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`NoInputAndOutputInput`](crate::operation::no_input_and_output::NoInputAndOutputInput).
          22  +
/* RustType.kt:516 */
   14     23   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          24  +
/* RustType.kt:516 */
   15     25   
#[non_exhaustive]
   16         -
pub struct NoInputAndOutputInputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct NoInputAndOutputInputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl NoInputAndOutputInputBuilder {
   18         -
    /// Consumes the builder and constructs a [`NoInputAndOutputInput`](crate::operation::no_input_and_output::NoInputAndOutputInput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`NoInputAndOutputInput`](crate::operation::no_input_and_output::NoInputAndOutputInput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(
   20     33   
        self,
   21     34   
    ) -> ::std::result::Result<crate::operation::no_input_and_output::NoInputAndOutputInput, ::aws_smithy_types::error::operation::BuildError> {
   22         -
        ::std::result::Result::Ok(crate::operation::no_input_and_output::NoInputAndOutputInput {})
          35  +
        /* BuilderGenerator.kt:254 */
          36  +
        ::std::result::Result::Ok(
          37  +
            /* BuilderGenerator.kt:477 */
          38  +
            crate::operation::no_input_and_output::NoInputAndOutputInput {
          39  +
            /* BuilderGenerator.kt:477 */}, /* BuilderGenerator.kt:254 */
          40  +
        )
          41  +
        /* BuilderGenerator.kt:253 */
   23     42   
    }
          43  +
    /* BuilderGenerator.kt:355 */
   24     44   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/no_input_and_output/_no_input_and_output_output.rs

@@ -1,1 +22,39 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct NoInputAndOutputOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct NoInputAndOutputOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl NoInputAndOutputOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`NoInputAndOutputOutput`](crate::operation::no_input_and_output::NoInputAndOutputOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`NoInputAndOutputOutput`](crate::operation::no_input_and_output::NoInputAndOutputOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::no_input_and_output::builders::NoInputAndOutputOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::no_input_and_output::builders::NoInputAndOutputOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`NoInputAndOutputOutput`](crate::operation::no_input_and_output::NoInputAndOutputOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`NoInputAndOutputOutput`](crate::operation::no_input_and_output::NoInputAndOutputOutput).
          22  +
/* RustType.kt:516 */
   14     23   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          24  +
/* RustType.kt:516 */
   15     25   
#[non_exhaustive]
   16         -
pub struct NoInputAndOutputOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct NoInputAndOutputOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl NoInputAndOutputOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`NoInputAndOutputOutput`](crate::operation::no_input_and_output::NoInputAndOutputOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`NoInputAndOutputOutput`](crate::operation::no_input_and_output::NoInputAndOutputOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::no_input_and_output::NoInputAndOutputOutput {
   20         -
        crate::operation::no_input_and_output::NoInputAndOutputOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::no_input_and_output::NoInputAndOutputOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/no_input_and_output/builders.rs

@@ -1,1 +111,123 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CodegenDelegator.kt:255 */
    2      3   
pub use crate::operation::no_input_and_output::_no_input_and_output_output::NoInputAndOutputOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::no_input_and_output::_no_input_and_output_input::NoInputAndOutputInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::no_input_and_output::builders::NoInputAndOutputInputBuilder {
    7     10   
    /// Sends a request with this input using the given client.
    8     11   
    pub async fn send_with(
    9     12   
        self,
   10     13   
        client: &crate::Client,
   11     14   
    ) -> ::std::result::Result<
   12     15   
        crate::operation::no_input_and_output::NoInputAndOutputOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::no_input_and_output::NoInputAndOutputError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.no_input_and_output();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `NoInputAndOutput`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `NoInputAndOutput`.
   24     27   
///
   25         -
/// The example tests how requests and responses are serialized when there's no request payload or response members. While this should be rare, code generators must support this.
          28  +
/// /* FluentBuilderGenerator.kt:130 */The example tests how requests and responses are serialized when there's no request payload or response members. While this should be rare, code generators must support this.
          29  +
/* RustType.kt:516 */
   26     30   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          31  +
/* FluentBuilderGenerator.kt:270 */
   27     32   
pub struct NoInputAndOutputFluentBuilder {
   28     33   
    handle: ::std::sync::Arc<crate::client::Handle>,
   29     34   
    inner: crate::operation::no_input_and_output::builders::NoInputAndOutputInputBuilder,
   30     35   
    config_override: ::std::option::Option<crate::config::Builder>,
   31     36   
}
          37  +
/* FluentBuilderGenerator.kt:381 */
   32     38   
impl
   33     39   
    crate::client::customize::internal::CustomizableSend<
   34     40   
        crate::operation::no_input_and_output::NoInputAndOutputOutput,
   35     41   
        crate::operation::no_input_and_output::NoInputAndOutputError,
   36     42   
    > for NoInputAndOutputFluentBuilder
   37     43   
{
   38     44   
    fn send(
   39     45   
        self,
   40     46   
        config_override: crate::config::Builder,
   41     47   
    ) -> crate::client::customize::internal::BoxFuture<
   42     48   
        crate::client::customize::internal::SendResult<
   43     49   
            crate::operation::no_input_and_output::NoInputAndOutputOutput,
   44     50   
            crate::operation::no_input_and_output::NoInputAndOutputError,
   45     51   
        >,
   46     52   
    > {
   47     53   
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
   48     54   
    }
   49     55   
}
          56  +
/* FluentBuilderGenerator.kt:282 */
   50     57   
impl NoInputAndOutputFluentBuilder {
          58  +
    /* FluentBuilderGenerator.kt:288 */
   51     59   
    /// Creates a new `NoInputAndOutputFluentBuilder`.
   52     60   
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
   53     61   
        Self {
   54     62   
            handle,
   55     63   
            inner: ::std::default::Default::default(),
   56     64   
            config_override: ::std::option::Option::None,
   57     65   
        }
   58     66   
    }
          67  +
    /* FluentBuilderGenerator.kt:301 */
   59     68   
    /// Access the NoInputAndOutput as a reference.
   60     69   
    pub fn as_input(&self) -> &crate::operation::no_input_and_output::builders::NoInputAndOutputInputBuilder {
   61     70   
        &self.inner
   62     71   
    }
          72  +
    /* FluentBuilderGenerator.kt:145 */
   63     73   
    /// Sends the request and returns the response.
   64     74   
    ///
   65     75   
    /// If an error occurs, an `SdkError` will be returned with additional details that
   66     76   
    /// can be matched against.
   67     77   
    ///
   68     78   
    /// By default, any retryable failures will be retried twice. Retry behavior
   69     79   
    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
   70     80   
    /// set when configuring the client.
   71     81   
    pub async fn send(
   72     82   
        self,
   73     83   
    ) -> ::std::result::Result<
   74     84   
        crate::operation::no_input_and_output::NoInputAndOutputOutput,
   75     85   
        ::aws_smithy_runtime_api::client::result::SdkError<
   76     86   
            crate::operation::no_input_and_output::NoInputAndOutputError,
   77     87   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   78     88   
        >,
   79     89   
    > {
   80     90   
        let input = self
   81     91   
            .inner
   82     92   
            .build()
   83     93   
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
   84     94   
        let runtime_plugins = crate::operation::no_input_and_output::NoInputAndOutput::operation_runtime_plugins(
   85     95   
            self.handle.runtime_plugins.clone(),
   86     96   
            &self.handle.conf,
   87     97   
            self.config_override,
   88     98   
        );
   89     99   
        crate::operation::no_input_and_output::NoInputAndOutput::orchestrate(&runtime_plugins, input).await
   90    100   
    }
   91    101   
   92    102   
    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
   93    103   
    pub fn customize(
   94    104   
        self,
   95    105   
    ) -> crate::client::customize::CustomizableOperation<
   96    106   
        crate::operation::no_input_and_output::NoInputAndOutputOutput,
   97    107   
        crate::operation::no_input_and_output::NoInputAndOutputError,
   98    108   
        Self,
   99    109   
    > {
  100    110   
        crate::client::customize::CustomizableOperation::new(self)
  101    111   
    }
         112  +
    /* FluentBuilderGenerator.kt:315 */
  102    113   
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
  103    114   
        self.set_config_override(::std::option::Option::Some(config_override.into()));
  104    115   
        self
  105    116   
    }
  106    117   
  107    118   
    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
  108    119   
        self.config_override = config_override;
  109    120   
        self
  110    121   
    }
         122  +
    /* FluentBuilderGenerator.kt:282 */
  111    123   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/put_with_content_encoding.rs

@@ -1,1 +40,49 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* OperationGenerator.kt:77 */
    2      3   
/// Orchestration and serialization glue logic for `PutWithContentEncoding`.
           4  +
/* RustType.kt:516 */
    3      5   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
           6  +
/* RustType.kt:516 */
    4      7   
#[non_exhaustive]
           8  +
/* OperationGenerator.kt:84 */
    5      9   
pub struct PutWithContentEncoding;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl PutWithContentEncoding {
    7         -
    /// Creates a new `PutWithContentEncoding`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `PutWithContentEncoding`
          13  +
    /* OperationGenerator.kt:87 */
    8     14   
    pub fn new() -> Self {
          15  +
        /* OperationGenerator.kt:88 */
    9     16   
        Self
          17  +
        /* OperationGenerator.kt:87 */
   10     18   
    }
          19  +
    /* OperationGenerator.kt:138 */
   11     20   
    pub(crate) async fn orchestrate(
   12     21   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     22   
        input: crate::operation::put_with_content_encoding::PutWithContentEncodingInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::put_with_content_encoding::PutWithContentEncodingError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -65,74 +402,478 @@
   85     94   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   86     95   
            }
   87     96   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   88     97   
                config_override,
   89     98   
                client_config.config.clone(),
   90     99   
                &client_config.runtime_components,
   91    100   
            ));
   92    101   
        }
   93    102   
        runtime_plugins
   94    103   
    }
         104  +
    /* OperationGenerator.kt:85 */
   95    105   
}
         106  +
/* OperationRuntimePluginGenerator.kt:55 */
   96    107   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for PutWithContentEncoding {
   97    108   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   98    109   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("PutWithContentEncoding");
   99    110   
  100    111   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
  101    112   
            PutWithContentEncodingRequestSerializer,
  102    113   
        ));
  103    114   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  104    115   
            PutWithContentEncodingResponseDeserializer,
  105    116   
        ));
  106    117   
  107    118   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  108    119   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  109    120   
        ));
  110    121   
  111    122   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  112    123   
            "PutWithContentEncoding",
  113    124   
            "EC2 Protocol",
  114    125   
        ));
  115    126   
  116    127   
        ::std::option::Option::Some(cfg.freeze())
  117    128   
    }
  118    129   
  119    130   
    fn runtime_components(
  120    131   
        &self,
  121    132   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  122    133   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  123    134   
        #[allow(unused_mut)]
  124    135   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("PutWithContentEncoding")
  125    136   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  126    137   
            .with_interceptor(PutWithContentEncodingEndpointParamsInterceptor)
  127    138   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  128    139   
                crate::operation::put_with_content_encoding::PutWithContentEncodingError,
  129    140   
            >::new())
  130    141   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  131    142   
                crate::operation::put_with_content_encoding::PutWithContentEncodingError,
  132    143   
            >::new());
  133    144   
  134    145   
        ::std::borrow::Cow::Owned(rcb)
  135    146   
    }
  136    147   
}
  137    148   
         149  +
/* ResponseDeserializerGenerator.kt:64 */
  138    150   
#[derive(Debug)]
  139    151   
struct PutWithContentEncodingResponseDeserializer;
  140    152   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for PutWithContentEncodingResponseDeserializer {
  141    153   
    fn deserialize_nonstreaming(
  142    154   
        &self,
  143    155   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  144    156   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  145    157   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  146    158   
        let headers = response.headers();
  147    159   
        let body = response.body().bytes().expect("body loaded");
  148    160   
        #[allow(unused_mut)]
  149    161   
        let mut force_error = false;
  150    162   
  151    163   
        let parse_result = if !success && status != 200 || force_error {
  152    164   
            crate::protocol_serde::shape_put_with_content_encoding::de_put_with_content_encoding_http_error(status, headers, body)
  153    165   
        } else {
  154    166   
            crate::protocol_serde::shape_put_with_content_encoding::de_put_with_content_encoding_http_response(status, headers, body)
  155    167   
        };
  156    168   
        crate::protocol_serde::type_erase_result(parse_result)
  157    169   
    }
  158    170   
}
         171  +
/* RequestSerializerGenerator.kt:67 */
  159    172   
#[derive(Debug)]
  160    173   
struct PutWithContentEncodingRequestSerializer;
  161    174   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for PutWithContentEncodingRequestSerializer {
  162    175   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  163    176   
    fn serialize_input(
  164    177   
        &self,
  165    178   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  166    179   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  167    180   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  168    181   
        let input = input
  169    182   
            .downcast::<crate::operation::put_with_content_encoding::PutWithContentEncodingInput>()
  170    183   
            .expect("correct type");
  171    184   
        let _header_serialization_settings = _cfg
  172    185   
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  173    186   
            .cloned()
  174    187   
            .unwrap_or_default();
  175    188   
        let mut request_builder = {
  176    189   
            fn uri_base(
  177    190   
                _input: &crate::operation::put_with_content_encoding::PutWithContentEncodingInput,
  178    191   
                output: &mut ::std::string::String,
  179    192   
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  180    193   
                use ::std::fmt::Write as _;
  181    194   
                ::std::write!(output, "/").expect("formatting should succeed");
  182    195   
                ::std::result::Result::Ok(())
  183    196   
            }
  184    197   
            #[allow(clippy::unnecessary_wraps)]
  185    198   
            fn update_http_builder(
  186    199   
                input: &crate::operation::put_with_content_encoding::PutWithContentEncodingInput,
  187    200   
                builder: ::http::request::Builder,
  188    201   
            ) -> ::std::result::Result<::http::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  189    202   
                let mut uri = ::std::string::String::new();
  190    203   
                uri_base(input, &mut uri)?;
  191    204   
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  192    205   
            }
  193    206   
            let mut builder = update_http_builder(&input, ::http::request::Builder::new())?;
  194    207   
            builder = _header_serialization_settings.set_default_header(builder, ::http::header::CONTENT_TYPE, "application/x-www-form-urlencoded");
  195    208   
            builder
  196    209   
        };
  197    210   
        let body = ::aws_smithy_types::body::SdkBody::from(
  198    211   
            crate::protocol_serde::shape_put_with_content_encoding_input::ser_put_with_content_encoding_input_input_input(&input)?,
  199    212   
        );
  200    213   
        if let Some(content_length) = body.content_length() {
  201    214   
            let content_length = content_length.to_string();
  202    215   
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http::header::CONTENT_LENGTH, &content_length);
  203    216   
        }
  204    217   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  205    218   
    }
  206    219   
}
         220  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  207    221   
#[derive(Debug)]
  208    222   
struct PutWithContentEncodingEndpointParamsInterceptor;
  209    223   
  210    224   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for PutWithContentEncodingEndpointParamsInterceptor {
  211    225   
    fn name(&self) -> &'static str {
  212    226   
        "PutWithContentEncodingEndpointParamsInterceptor"
  213    227   
    }
  214    228   
  215    229   
    fn read_before_execution(
  216    230   
        &self,
  217    231   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  218    232   
            '_,
  219    233   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  220    234   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  221    235   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  222    236   
        >,
  223    237   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  224    238   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  225    239   
        let _input = context
  226    240   
            .input()
  227    241   
            .downcast_ref::<PutWithContentEncodingInput>()
  228    242   
            .ok_or("failed to downcast to PutWithContentEncodingInput")?;
  229    243   
  230    244   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  231    245   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  232    246   
        })?;
  233    247   
        cfg.interceptor_state()
  234    248   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  235    249   
        ::std::result::Result::Ok(())
  236    250   
    }
  237    251   
}
  238    252   
  239    253   
// The get_* functions below are generated from JMESPath expressions in the
  240    254   
// operationContextParams trait. They target the operation's input shape.
  241    255   
         256  +
/* RustType.kt:516 */
  242    257   
#[allow(unreachable_code, unused_variables)]
         258  +
/* RustType.kt:516 */
  243    259   
#[cfg(test)]
         260  +
/* ProtocolTestGenerator.kt:98 */
  244    261   
mod put_with_content_encoding_test {
  245    262   
  246    263   
    /// Compression algorithm encoding is appended to the Content-Encoding header.
  247    264   
    /// Test ID: SDKAppliedContentEncoding_ec2Query
  248    265   
    #[::tokio::test]
  249    266   
    #[::tracing_test::traced_test]
  250    267   
    async fn sdk_applied_content_encoding_ec2_query_request() {
  251    268   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  252    269   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  253    270   
  254    271   
        let client = crate::Client::from_conf(config_builder.http_client(http_client).build());
  255    272   
        let result = client.put_with_content_encoding()
  256    273   
        .set_data(
  257    274   
            ::std::option::Option::Some(
  258    275   
                "RjCEL3kBwqPivZUXGiyA5JCujtWgJAkKRlnTEsNYfBRGOS0f7LT6R3bCSOXeJ4auSHzQ4BEZZTklUyj5\n1HEojihShQC2jkQJrNdGOZNSW49yRO0XbnGmeczUHbZqZRelLFKW4xjru9uTuB8lFCtwoGgciFsgqTF8\n5HYcoqINTRxuAwGuRUMoNO473QT0BtCQoKUkAyVaypG0hBZdGNoJhunBfW0d3HWTYlzz9pXElyZhq3C1\n2PDB17GEoOYXmTxDecysmPOdo5z6T0HFhujfeJFIQQ8dirmXcG4F3v0bZdf6AZ3jsiVh6RnEXIPxPbOi\ngIXDWTMUr4Pg3f2LdYCM01eAb2qTdgsEN0MUDhEIfn68I2tnWvcozyUFpg1ez6pyWP8ssWVfFrckREIM\nMb0cTUVqSVSM8bnFiF9SoXM6ZoGMKfX1mT708OYk7SqZ1JlCTkecDJDoR5ED2q2MWKUGR6jjnEV0GtD8\nWJO6AcF0DptY9Hk16Bav3z6c5FeBvrGDrxTFVgRUk8SychzjrcqJ4qskwN8rL3zslC0oqobQRnLFOvwJ\nprSzBIwdH2yAuxokXAdVRa1u9NGNRvfWJfKkwbbVz8yV76RUF9KNhAUmwyYDrLnxNj8ROl8B7dv8Gans\n7Bit52wcdiJyjBW1pAodB7zqqVwtBx5RaSpF7kEMXexYXp9N0J1jlXzdeg5Wgg4pO7TJNr2joiPVAiFf\nefwMMCNBkYx2z7cRxVxCJZMXXzxSKMGgdTN24bJ5UgE0Tx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    276   
            )
  260    277   
        )
  261    278   
        .send().await;
  262    279   
        let _ = dbg!(result);
  263    280   
        let http_request = request_receiver.expect_request();
  264    281   
        let expected_headers = [("Content-Encoding", "gzip")];
  265    282   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(http_request.headers(), expected_headers));
  266    283   
        let uri: ::http::Uri = http_request.uri().parse().expect("invalid URI sent");
  267    284   
        ::pretty_assertions::assert_eq!(http_request.method(), "POST", "method was incorrect");
  268    285   
        ::pretty_assertions::assert_eq!(uri.path(), "/", "path was incorrect");
  269    286   
    }
  270    287   
  271    288   
    /// Compression algorithm encoding is appended to the Content-Encoding header, and the
  272    289   
    /// user-provided content-encoding is NOT in the Content-Encoding header since HTTP binding
  273    290   
    /// traits are ignored in the ec2Query protocol.
  274    291   
    ///
  275    292   
    /// Test ID: SDKAppendsGzipAndIgnoresHttpProvidedEncoding_ec2Query
  276    293   
    #[::tokio::test]
  277    294   
    #[::tracing_test::traced_test]
  278    295   
    async fn sdk_appends_gzip_and_ignores_http_provided_encoding_ec2_query_request() {
  279    296   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  280    297   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  281    298   
  282    299   
        let client = crate::Client::from_conf(config_builder.http_client(http_client).build());
  283    300   
        let result = client.put_with_content_encoding()
  284    301   
        .set_encoding(
  285    302   
            ::std::option::Option::Some(
  286    303   
                "custom".to_owned()
  287    304   
            )
  288    305   
        )
  289    306   
        .set_data(
  290    307   
            ::std::option::Option::Some(
  291    308   
                "RjCEL3kBwqPivZUXGiyA5JCujtWgJAkKRlnTEsNYfBRGOS0f7LT6R3bCSOXeJ4auSHzQ4BEZZTklUyj5\n1HEojihShQC2jkQJrNdGOZNSW49yRO0XbnGmeczUHbZqZRelLFKW4xjru9uTuB8lFCtwoGgciFsgqTF8\n5HYcoqINTRxuAwGuRUMoNO473QT0BtCQoKUkAyVaypG0hBZdGNo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CtoplC6hhpKmW5dQo92iCTyY2KioKzO8XR6FKm6qonMKVEwQNtlYE9c97KMtEnp25VOdMP46SQXS\nYsSVp7vm8LP87VYI8SOKcW3s2oedYFtt45rvDzoTF0GmS6wELQ9uo98HhjQAI1Dt91cgjJOwygNmLoZE\nX5K2zQiNA163uMCl5xzaBqY4YTL0wgALg3IFdYSp0RFYLWdt6IxoGI1tnoxcjlUEPo5eGIc3mS3SmaLn\nOdumfUQQ4Jgmgaa5anUVQsfBDrlAN5oaX7O0JO71SSPSWiHBsT9WIPy2J1Cace9ZZLRxblFPSXcvsuHh\nhvnhWQltEDAe7MgvkFQ8lGVFa8jhzijoF9kLmMhMILSzYnfXnZPNP7TlAAwlLHK1RqlpHskJqb6CPpGP\nQvOAhEMsM3zJ2KejZx0esxkjxA0ZufVvGAMN3vTUMplQaF4RiQkp9fzBXf3CMk01dWjOMMIEXTeKzIQe\nEcffzjixWU9FpAyGp2rVl4ETRgqljOGw4UgK31r0ZIEGnH0xGz1FtbW1OcQM008JVujRqulCucEMmntr\n".to_owned()
  292    309   
            )
  293    310   
        )
  294    311   
        .send().await;
  295    312   
        let _ = dbg!(result);
  296    313   
        let http_request = request_receiver.expect_request();
  297    314   
        let expected_headers = [("Content-Encoding", "gzip")];
  298    315   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(http_request.headers(), expected_headers));
  299    316   
        let uri: ::http::Uri = http_request.uri().parse().expect("invalid URI sent");
  300    317   
        ::pretty_assertions::assert_eq!(http_request.method(), "POST", "method was incorrect");
  301    318   
        ::pretty_assertions::assert_eq!(uri.path(), "/", "path was incorrect");
  302    319   
    }
         320  +
         321  +
    /* ProtocolTestGenerator.kt:98 */
  303    322   
}
  304    323   
         324  +
/* OperationErrorGenerator.kt:79 */
  305    325   
/// Error type for the `PutWithContentEncodingError` operation.
         326  +
/* RustType.kt:516 */
  306    327   
#[non_exhaustive]
         328  +
/* RustType.kt:516 */
  307    329   
#[derive(::std::fmt::Debug)]
  308         -
pub enum PutWithContentEncodingError {
         330  +
pub /* OperationErrorGenerator.kt:81 */ enum PutWithContentEncodingError {
         331  +
    /* OperationErrorGenerator.kt:88 */
  309    332   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  310    333   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  311    334   
    variable wildcard pattern and check `.code()`:
  312    335   
     \
  313    336   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  314    337   
     \
  315    338   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-PutWithContentEncodingError) for what information is available for the error.")]
  316    339   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         340  +
    /* OperationErrorGenerator.kt:81 */
  317    341   
}
         342  +
/* OperationErrorGenerator.kt:218 */
  318    343   
impl PutWithContentEncodingError {
         344  +
    /* OperationErrorGenerator.kt:219 */
  319    345   
    /// Creates the `PutWithContentEncodingError::Unhandled` variant from any error type.
  320    346   
    pub fn unhandled(
  321    347   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  322    348   
    ) -> Self {
  323    349   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  324    350   
            source: err.into(),
  325    351   
            meta: ::std::default::Default::default(),
  326    352   
        })
  327    353   
    }
  328    354   
  329    355   
    /// Creates the `PutWithContentEncodingError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  330    356   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  331    357   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  332    358   
            source: err.clone().into(),
  333    359   
            meta: err,
  334    360   
        })
  335    361   
    }
  336         -
    ///
         362  +
    /// /* OperationErrorGenerator.kt:236 */
  337    363   
    /// Returns error metadata, which includes the error code, message,
  338    364   
    /// request ID, and potentially additional information.
  339    365   
    ///
         366  +
    /* OperationErrorGenerator.kt:242 */
  340    367   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         368  +
        /* OperationErrorGenerator.kt:243 */
  341    369   
        match self {
  342         -
            Self::Unhandled(e) => &e.meta,
         370  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         371  +
            /* OperationErrorGenerator.kt:243 */
  343    372   
        }
         373  +
        /* OperationErrorGenerator.kt:242 */
  344    374   
    }
         375  +
    /* OperationErrorGenerator.kt:218 */
  345    376   
}
         377  +
/* OperationErrorGenerator.kt:269 */
  346    378   
impl ::std::error::Error for PutWithContentEncodingError {
         379  +
    /* OperationErrorGenerator.kt:270 */
  347    380   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         381  +
        /* OperationErrorGenerator.kt:318 */
  348    382   
        match self {
  349         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         383  +
            /* OperationErrorGenerator.kt:326 */
         384  +
            Self::Unhandled(_inner) => {
         385  +
                /* OperationErrorGenerator.kt:279 */
         386  +
                ::std::option::Option::Some(&*_inner.source)
         387  +
                /* OperationErrorGenerator.kt:326 */
         388  +
            } /* OperationErrorGenerator.kt:318 */
  350    389   
        }
         390  +
        /* OperationErrorGenerator.kt:270 */
  351    391   
    }
         392  +
    /* OperationErrorGenerator.kt:269 */
  352    393   
}
         394  +
/* OperationErrorGenerator.kt:133 */
  353    395   
impl ::std::fmt::Display for PutWithContentEncodingError {
         396  +
    /* OperationErrorGenerator.kt:134 */
  354    397   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         398  +
        /* OperationErrorGenerator.kt:318 */
  355    399   
        match self {
         400  +
            /* OperationErrorGenerator.kt:326 */
  356    401   
            Self::Unhandled(_inner) => {
         402  +
                /* OperationErrorGenerator.kt:139 */
  357    403   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  358    404   
                    write!(f, "unhandled error ({code})")
  359    405   
                } else {
  360    406   
                    f.write_str("unhandled error")
  361    407   
                }
         408  +
                /* OperationErrorGenerator.kt:326 */
         409  +
            } /* OperationErrorGenerator.kt:318 */
  362    410   
        }
         411  +
        /* OperationErrorGenerator.kt:134 */
  363    412   
    }
  364         -
    }
         413  +
    /* OperationErrorGenerator.kt:133 */
  365    414   
}
         415  +
/* OperationErrorGenerator.kt:182 */
  366    416   
impl ::aws_smithy_types::retry::ProvideErrorKind for PutWithContentEncodingError {
         417  +
    /* OperationErrorGenerator.kt:186 */
  367    418   
    fn code(&self) -> ::std::option::Option<&str> {
         419  +
        /* OperationErrorGenerator.kt:187 */
  368    420   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         421  +
        /* OperationErrorGenerator.kt:186 */
  369    422   
    }
         423  +
    /* OperationErrorGenerator.kt:190 */
  370    424   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         425  +
        /* OperationErrorGenerator.kt:197 */
  371    426   
        ::std::option::Option::None
         427  +
        /* OperationErrorGenerator.kt:190 */
  372    428   
    }
         429  +
    /* OperationErrorGenerator.kt:182 */
  373    430   
}
         431  +
/* OperationErrorGenerator.kt:163 */
  374    432   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for PutWithContentEncodingError {
         433  +
    /* OperationErrorGenerator.kt:164 */
  375    434   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         435  +
        /* OperationErrorGenerator.kt:318 */
  376    436   
        match self {
  377         -
            Self::Unhandled(_inner) => &_inner.meta,
         437  +
            /* OperationErrorGenerator.kt:326 */
         438  +
            Self::Unhandled(_inner) => {
         439  +
                /* OperationErrorGenerator.kt:168 */
         440  +
                &_inner.meta
         441  +
                /* OperationErrorGenerator.kt:326 */
         442  +
            } /* OperationErrorGenerator.kt:318 */
  378    443   
        }
         444  +
        /* OperationErrorGenerator.kt:164 */
  379    445   
    }
         446  +
    /* OperationErrorGenerator.kt:163 */
  380    447   
}
         448  +
/* OperationErrorGenerator.kt:109 */
  381    449   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for PutWithContentEncodingError {
         450  +
    /* OperationErrorGenerator.kt:110 */
  382    451   
    fn create_unhandled_error(
  383    452   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  384    453   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  385    454   
    ) -> Self {
         455  +
        /* OperationErrorGenerator.kt:121 */
  386    456   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  387    457   
            source,
  388    458   
            meta: meta.unwrap_or_default(),
  389    459   
        })
         460  +
        /* OperationErrorGenerator.kt:110 */
  390    461   
    }
         462  +
    /* OperationErrorGenerator.kt:109 */
  391    463   
}
  392    464   
         465  +
/* CodegenDelegator.kt:255 */
  393    466   
pub use crate::operation::put_with_content_encoding::_put_with_content_encoding_output::PutWithContentEncodingOutput;
  394    467   
         468  +
/* CodegenDelegator.kt:255 */
  395    469   
pub use crate::operation::put_with_content_encoding::_put_with_content_encoding_input::PutWithContentEncodingInput;
  396    470   
         471  +
/* RustModule.kt:172 */
  397    472   
mod _put_with_content_encoding_input;
  398    473   
         474  +
/* RustModule.kt:172 */
  399    475   
mod _put_with_content_encoding_output;
  400    476   
  401         -
/// Builders
         477  +
/// /* CodegenDelegator.kt:51 */Builders
  402    478   
pub mod builders;

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/put_with_content_encoding/_put_with_content_encoding_input.rs

@@ -1,1 +76,137 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct PutWithContentEncodingInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct PutWithContentEncodingInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub encoding: ::std::option::Option<::std::string::String>,
          12  +
    /* StructureGenerator.kt:231 */
    8     13   
    #[allow(missing_docs)] // documentation missing in model
    9     14   
    pub data: ::std::option::Option<::std::string::String>,
          15  +
    /* StructureGenerator.kt:201 */
   10     16   
}
          17  +
/* StructureGenerator.kt:135 */
   11     18   
impl PutWithContentEncodingInput {
          19  +
    /* StructureGenerator.kt:231 */
   12     20   
    #[allow(missing_docs)] // documentation missing in model
          21  +
                           /* StructureGenerator.kt:166 */
   13     22   
    pub fn encoding(&self) -> ::std::option::Option<&str> {
          23  +
        /* StructureGenerator.kt:169 */
   14     24   
        self.encoding.as_deref()
          25  +
        /* StructureGenerator.kt:166 */
   15     26   
    }
          27  +
    /* StructureGenerator.kt:231 */
   16     28   
    #[allow(missing_docs)] // documentation missing in model
          29  +
                           /* StructureGenerator.kt:166 */
   17     30   
    pub fn data(&self) -> ::std::option::Option<&str> {
          31  +
        /* StructureGenerator.kt:169 */
   18     32   
        self.data.as_deref()
          33  +
        /* StructureGenerator.kt:166 */
   19     34   
    }
          35  +
    /* StructureGenerator.kt:135 */
   20     36   
}
          37  +
/* ClientCodegenVisitor.kt:237 */
   21     38   
impl PutWithContentEncodingInput {
   22         -
    /// Creates a new builder-style object to manufacture [`PutWithContentEncodingInput`](crate::operation::put_with_content_encoding::PutWithContentEncodingInput).
          39  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`PutWithContentEncodingInput`](crate::operation::put_with_content_encoding::PutWithContentEncodingInput).
          40  +
    /* BuilderGenerator.kt:175 */
   23     41   
    pub fn builder() -> crate::operation::put_with_content_encoding::builders::PutWithContentEncodingInputBuilder {
          42  +
        /* BuilderGenerator.kt:176 */
   24     43   
        crate::operation::put_with_content_encoding::builders::PutWithContentEncodingInputBuilder::default()
          44  +
        /* BuilderGenerator.kt:175 */
   25     45   
    }
          46  +
    /* ClientCodegenVisitor.kt:237 */
   26     47   
}
   27     48   
   28         -
/// A builder for [`PutWithContentEncodingInput`](crate::operation::put_with_content_encoding::PutWithContentEncodingInput).
          49  +
/// /* BuilderGenerator.kt:342 */A builder for [`PutWithContentEncodingInput`](crate::operation::put_with_content_encoding::PutWithContentEncodingInput).
          50  +
/* RustType.kt:516 */
   29     51   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          52  +
/* RustType.kt:516 */
   30     53   
#[non_exhaustive]
          54  +
/* BuilderGenerator.kt:345 */
   31     55   
pub struct PutWithContentEncodingInputBuilder {
   32         -
    pub(crate) encoding: ::std::option::Option<::std::string::String>,
   33         -
    pub(crate) data: ::std::option::Option<::std::string::String>,
          56  +
    /* BuilderGenerator.kt:275 */ pub(crate) encoding: ::std::option::Option<::std::string::String>,
          57  +
    /* BuilderGenerator.kt:275 */ pub(crate) data: ::std::option::Option<::std::string::String>,
          58  +
    /* BuilderGenerator.kt:345 */
   34     59   
}
          60  +
/* BuilderGenerator.kt:355 */
   35     61   
impl PutWithContentEncodingInputBuilder {
          62  +
    /* BuilderGenerator.kt:286 */
   36     63   
    #[allow(missing_docs)] // documentation missing in model
          64  +
                           /* BuilderGenerator.kt:291 */
   37     65   
    pub fn encoding(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
          66  +
        /* BuilderGenerator.kt:292 */
   38     67   
        self.encoding = ::std::option::Option::Some(input.into());
          68  +
        /* BuilderGenerator.kt:293 */
   39     69   
        self
          70  +
        /* BuilderGenerator.kt:291 */
   40     71   
    }
          72  +
    /* BuilderGenerator.kt:312 */
   41     73   
    #[allow(missing_docs)] // documentation missing in model
          74  +
                           /* BuilderGenerator.kt:314 */
   42     75   
    pub fn set_encoding(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
          76  +
        /* BuilderGenerator.kt:315 */
   43     77   
        self.encoding = input;
   44     78   
        self
          79  +
        /* BuilderGenerator.kt:314 */
   45     80   
    }
          81  +
    /* BuilderGenerator.kt:334 */
   46     82   
    #[allow(missing_docs)] // documentation missing in model
          83  +
                           /* BuilderGenerator.kt:336 */
   47     84   
    pub fn get_encoding(&self) -> &::std::option::Option<::std::string::String> {
          85  +
        /* BuilderGenerator.kt:337 */
   48     86   
        &self.encoding
          87  +
        /* BuilderGenerator.kt:336 */
   49     88   
    }
          89  +
    /* BuilderGenerator.kt:286 */
   50     90   
    #[allow(missing_docs)] // documentation missing in model
          91  +
                           /* BuilderGenerator.kt:291 */
   51     92   
    pub fn data(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
          93  +
        /* BuilderGenerator.kt:292 */
   52     94   
        self.data = ::std::option::Option::Some(input.into());
          95  +
        /* BuilderGenerator.kt:293 */
   53     96   
        self
          97  +
        /* BuilderGenerator.kt:291 */
   54     98   
    }
          99  +
    /* BuilderGenerator.kt:312 */
   55    100   
    #[allow(missing_docs)] // documentation missing in model
         101  +
                           /* BuilderGenerator.kt:314 */
   56    102   
    pub fn set_data(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
         103  +
        /* BuilderGenerator.kt:315 */
   57    104   
        self.data = input;
   58    105   
        self
         106  +
        /* BuilderGenerator.kt:314 */
   59    107   
    }
         108  +
    /* BuilderGenerator.kt:334 */
   60    109   
    #[allow(missing_docs)] // documentation missing in model
         110  +
                           /* BuilderGenerator.kt:336 */
   61    111   
    pub fn get_data(&self) -> &::std::option::Option<::std::string::String> {
         112  +
        /* BuilderGenerator.kt:337 */
   62    113   
        &self.data
         114  +
        /* BuilderGenerator.kt:336 */
   63    115   
    }
   64         -
    /// Consumes the builder and constructs a [`PutWithContentEncodingInput`](crate::operation::put_with_content_encoding::PutWithContentEncodingInput).
         116  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`PutWithContentEncodingInput`](crate::operation::put_with_content_encoding::PutWithContentEncodingInput).
         117  +
    /* BuilderGenerator.kt:253 */
   65    118   
    pub fn build(
   66    119   
        self,
   67    120   
    ) -> ::std::result::Result<
   68    121   
        crate::operation::put_with_content_encoding::PutWithContentEncodingInput,
   69    122   
        ::aws_smithy_types::error::operation::BuildError,
   70    123   
    > {
   71         -
        ::std::result::Result::Ok(crate::operation::put_with_content_encoding::PutWithContentEncodingInput {
   72         -
            encoding: self.encoding,
         124  +
        /* BuilderGenerator.kt:254 */
         125  +
        ::std::result::Result::Ok(
         126  +
            /* BuilderGenerator.kt:477 */
         127  +
            crate::operation::put_with_content_encoding::PutWithContentEncodingInput {
         128  +
                /* BuilderGenerator.kt:481 */ encoding: self.encoding,
         129  +
                /* BuilderGenerator.kt:481 */
   73    130   
                data: self.data,
   74         -
        })
         131  +
                /* BuilderGenerator.kt:477 */
         132  +
            }, /* BuilderGenerator.kt:254 */
         133  +
        )
         134  +
        /* BuilderGenerator.kt:253 */
   75    135   
    }
         136  +
    /* BuilderGenerator.kt:355 */
   76    137   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/put_with_content_encoding/_put_with_content_encoding_output.rs

@@ -1,1 +22,39 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct PutWithContentEncodingOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct PutWithContentEncodingOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl PutWithContentEncodingOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`PutWithContentEncodingOutput`](crate::operation::put_with_content_encoding::PutWithContentEncodingOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`PutWithContentEncodingOutput`](crate::operation::put_with_content_encoding::PutWithContentEncodingOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::put_with_content_encoding::builders::PutWithContentEncodingOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::put_with_content_encoding::builders::PutWithContentEncodingOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`PutWithContentEncodingOutput`](crate::operation::put_with_content_encoding::PutWithContentEncodingOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`PutWithContentEncodingOutput`](crate::operation::put_with_content_encoding::PutWithContentEncodingOutput).
          22  +
/* RustType.kt:516 */
   14     23   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          24  +
/* RustType.kt:516 */
   15     25   
#[non_exhaustive]
   16         -
pub struct PutWithContentEncodingOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct PutWithContentEncodingOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl PutWithContentEncodingOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`PutWithContentEncodingOutput`](crate::operation::put_with_content_encoding::PutWithContentEncodingOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`PutWithContentEncodingOutput`](crate::operation::put_with_content_encoding::PutWithContentEncodingOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::put_with_content_encoding::PutWithContentEncodingOutput {
   20         -
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/put_with_content_encoding/builders.rs

@@ -1,1 +138,162 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CodegenDelegator.kt:255 */
    2      3   
pub use crate::operation::put_with_content_encoding::_put_with_content_encoding_output::PutWithContentEncodingOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::put_with_content_encoding::_put_with_content_encoding_input::PutWithContentEncodingInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::put_with_content_encoding::builders::PutWithContentEncodingInputBuilder {
    7     10   
    /// Sends a request with this input using the given client.
    8     11   
    pub async fn send_with(
    9     12   
        self,
   10     13   
        client: &crate::Client,
   11     14   
    ) -> ::std::result::Result<
   12     15   
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::put_with_content_encoding::PutWithContentEncodingError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.put_with_content_encoding();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `PutWithContentEncoding`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `PutWithContentEncoding`.
   24     27   
///
          28  +
/* RustType.kt:516 */
   25     29   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          30  +
/* FluentBuilderGenerator.kt:270 */
   26     31   
pub struct PutWithContentEncodingFluentBuilder {
   27     32   
    handle: ::std::sync::Arc<crate::client::Handle>,
   28     33   
    inner: crate::operation::put_with_content_encoding::builders::PutWithContentEncodingInputBuilder,
   29     34   
    config_override: ::std::option::Option<crate::config::Builder>,
   30     35   
}
          36  +
/* FluentBuilderGenerator.kt:381 */
   31     37   
impl
   32     38   
    crate::client::customize::internal::CustomizableSend<
   33     39   
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput,
   34     40   
        crate::operation::put_with_content_encoding::PutWithContentEncodingError,
   35     41   
    > for PutWithContentEncodingFluentBuilder
   36     42   
{
   37     43   
    fn send(
   38     44   
        self,
   39     45   
        config_override: crate::config::Builder,
   40     46   
    ) -> crate::client::customize::internal::BoxFuture<
   41     47   
        crate::client::customize::internal::SendResult<
   42     48   
            crate::operation::put_with_content_encoding::PutWithContentEncodingOutput,
   43     49   
            crate::operation::put_with_content_encoding::PutWithContentEncodingError,
   44     50   
        >,
   45     51   
    > {
   46     52   
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
   47     53   
    }
   48     54   
}
          55  +
/* FluentBuilderGenerator.kt:282 */
   49     56   
impl PutWithContentEncodingFluentBuilder {
          57  +
    /* FluentBuilderGenerator.kt:288 */
   50     58   
    /// Creates a new `PutWithContentEncodingFluentBuilder`.
   51     59   
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
   52     60   
        Self {
   53     61   
            handle,
   54     62   
            inner: ::std::default::Default::default(),
   55     63   
            config_override: ::std::option::Option::None,
   56     64   
        }
   57     65   
    }
          66  +
    /* FluentBuilderGenerator.kt:301 */
   58     67   
    /// Access the PutWithContentEncoding as a reference.
   59     68   
    pub fn as_input(&self) -> &crate::operation::put_with_content_encoding::builders::PutWithContentEncodingInputBuilder {
   60     69   
        &self.inner
   61     70   
    }
          71  +
    /* FluentBuilderGenerator.kt:145 */
   62     72   
    /// Sends the request and returns the response.
   63     73   
    ///
   64     74   
    /// If an error occurs, an `SdkError` will be returned with additional details that
   65     75   
    /// can be matched against.
   66     76   
    ///
   67     77   
    /// By default, any retryable failures will be retried twice. Retry behavior
   68     78   
    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
   69     79   
    /// set when configuring the client.
   70     80   
    pub async fn send(
   71     81   
        self,
   72     82   
    ) -> ::std::result::Result<
   73     83   
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput,
   74     84   
        ::aws_smithy_runtime_api::client::result::SdkError<
   75     85   
            crate::operation::put_with_content_encoding::PutWithContentEncodingError,
   76     86   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   77     87   
        >,
   78     88   
    > {
   79     89   
        let input = self
   80     90   
            .inner
   81     91   
            .build()
   82     92   
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
   83     93   
        let runtime_plugins = crate::operation::put_with_content_encoding::PutWithContentEncoding::operation_runtime_plugins(
   84     94   
            self.handle.runtime_plugins.clone(),
   85     95   
            &self.handle.conf,
   86     96   
            self.config_override,
   87     97   
        );
   88     98   
        crate::operation::put_with_content_encoding::PutWithContentEncoding::orchestrate(&runtime_plugins, input).await
   89     99   
    }
   90    100   
   91    101   
    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
   92    102   
    pub fn customize(
   93    103   
        self,
   94    104   
    ) -> crate::client::customize::CustomizableOperation<
   95    105   
        crate::operation::put_with_content_encoding::PutWithContentEncodingOutput,
   96    106   
        crate::operation::put_with_content_encoding::PutWithContentEncodingError,
   97    107   
        Self,
   98    108   
    > {
   99    109   
        crate::client::customize::CustomizableOperation::new(self)
  100    110   
    }
         111  +
    /* FluentBuilderGenerator.kt:315 */
  101    112   
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
  102    113   
        self.set_config_override(::std::option::Option::Some(config_override.into()));
  103    114   
        self
  104    115   
    }
  105    116   
  106    117   
    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
  107    118   
        self.config_override = config_override;
  108    119   
        self
  109    120   
    }
         121  +
    /* FluentBuilderGenerator.kt:498 */
  110    122   
    #[allow(missing_docs)] // documentation missing in model
         123  +
                           /* FluentBuilderGenerator.kt:500 */
  111    124   
    pub fn encoding(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
  112    125   
        self.inner = self.inner.encoding(input.into());
  113    126   
        self
  114    127   
    }
         128  +
    /* FluentBuilderGenerator.kt:498 */
  115    129   
    #[allow(missing_docs)] // documentation missing in model
         130  +
                           /* FluentBuilderGenerator.kt:500 */
  116    131   
    pub fn set_encoding(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
  117    132   
        self.inner = self.inner.set_encoding(input);
  118    133   
        self
  119    134   
    }
         135  +
    /* FluentBuilderGenerator.kt:518 */
  120    136   
    #[allow(missing_docs)] // documentation missing in model
         137  +
                           /* FluentBuilderGenerator.kt:520 */
  121    138   
    pub fn get_encoding(&self) -> &::std::option::Option<::std::string::String> {
  122    139   
        self.inner.get_encoding()
  123    140   
    }
         141  +
    /* FluentBuilderGenerator.kt:498 */
  124    142   
    #[allow(missing_docs)] // documentation missing in model
         143  +
                           /* FluentBuilderGenerator.kt:500 */
  125    144   
    pub fn data(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
  126    145   
        self.inner = self.inner.data(input.into());
  127    146   
        self
  128    147   
    }
         148  +
    /* FluentBuilderGenerator.kt:498 */
  129    149   
    #[allow(missing_docs)] // documentation missing in model
         150  +
                           /* FluentBuilderGenerator.kt:500 */
  130    151   
    pub fn set_data(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
  131    152   
        self.inner = self.inner.set_data(input);
  132    153   
        self
  133    154   
    }
         155  +
    /* FluentBuilderGenerator.kt:518 */
  134    156   
    #[allow(missing_docs)] // documentation missing in model
         157  +
                           /* FluentBuilderGenerator.kt:520 */
  135    158   
    pub fn get_data(&self) -> &::std::option::Option<::std::string::String> {
  136    159   
        self.inner.get_data()
  137    160   
    }
         161  +
    /* FluentBuilderGenerator.kt:282 */
  138    162   
}

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/query_idempotency_token_auto_fill.rs

@@ -1,1 +40,49 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* OperationGenerator.kt:77 */
    2      3   
/// Orchestration and serialization glue logic for `QueryIdempotencyTokenAutoFill`.
           4  +
/* RustType.kt:516 */
    3      5   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
           6  +
/* RustType.kt:516 */
    4      7   
#[non_exhaustive]
           8  +
/* OperationGenerator.kt:84 */
    5      9   
pub struct QueryIdempotencyTokenAutoFill;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl QueryIdempotencyTokenAutoFill {
    7         -
    /// Creates a new `QueryIdempotencyTokenAutoFill`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `QueryIdempotencyTokenAutoFill`
          13  +
    /* OperationGenerator.kt:87 */
    8     14   
    pub fn new() -> Self {
          15  +
        /* OperationGenerator.kt:88 */
    9     16   
        Self
          17  +
        /* OperationGenerator.kt:87 */
   10     18   
    }
          19  +
    /* OperationGenerator.kt:138 */
   11     20   
    pub(crate) async fn orchestrate(
   12     21   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     22   
        input: crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -73,82 +410,486 @@
   93    102   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   94    103   
            }
   95    104   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   96    105   
                config_override,
   97    106   
                client_config.config.clone(),
   98    107   
                &client_config.runtime_components,
   99    108   
            ));
  100    109   
        }
  101    110   
        runtime_plugins
  102    111   
    }
         112  +
    /* OperationGenerator.kt:85 */
  103    113   
}
         114  +
/* OperationRuntimePluginGenerator.kt:55 */
  104    115   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for QueryIdempotencyTokenAutoFill {
  105    116   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
  106    117   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("QueryIdempotencyTokenAutoFill");
  107    118   
  108    119   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
  109    120   
            QueryIdempotencyTokenAutoFillRequestSerializer,
  110    121   
        ));
  111    122   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  112    123   
            QueryIdempotencyTokenAutoFillResponseDeserializer,
  113    124   
        ));
  114    125   
  115    126   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  116    127   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  117    128   
        ));
  118    129   
  119    130   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  120    131   
            "QueryIdempotencyTokenAutoFill",
  121    132   
            "EC2 Protocol",
  122    133   
        ));
  123    134   
  124    135   
        ::std::option::Option::Some(cfg.freeze())
  125    136   
    }
  126    137   
  127    138   
    fn runtime_components(
  128    139   
        &self,
  129    140   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  130    141   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  131    142   
        #[allow(unused_mut)]
  132    143   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("QueryIdempotencyTokenAutoFill")
  133    144   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  134    145   
            .with_interceptor(QueryIdempotencyTokenAutoFillEndpointParamsInterceptor)
  135    146   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  136    147   
                crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillError,
  137    148   
            >::new())
  138    149   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  139    150   
                crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillError,
  140    151   
            >::new());
  141    152   
  142    153   
        ::std::borrow::Cow::Owned(rcb)
  143    154   
    }
  144    155   
}
  145    156   
         157  +
/* ResponseDeserializerGenerator.kt:64 */
  146    158   
#[derive(Debug)]
  147    159   
struct QueryIdempotencyTokenAutoFillResponseDeserializer;
  148    160   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for QueryIdempotencyTokenAutoFillResponseDeserializer {
  149    161   
    fn deserialize_nonstreaming(
  150    162   
        &self,
  151    163   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  152    164   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  153    165   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  154    166   
        let headers = response.headers();
  155    167   
        let body = response.body().bytes().expect("body loaded");
  156    168   
        #[allow(unused_mut)]
  157    169   
        let mut force_error = false;
  158    170   
  159    171   
        let parse_result = if !success && status != 200 || force_error {
  160    172   
            crate::protocol_serde::shape_query_idempotency_token_auto_fill::de_query_idempotency_token_auto_fill_http_error(status, headers, body)
  161    173   
        } else {
  162    174   
            crate::protocol_serde::shape_query_idempotency_token_auto_fill::de_query_idempotency_token_auto_fill_http_response(status, headers, body)
  163    175   
        };
  164    176   
        crate::protocol_serde::type_erase_result(parse_result)
  165    177   
    }
  166    178   
}
         179  +
/* RequestSerializerGenerator.kt:67 */
  167    180   
#[derive(Debug)]
  168    181   
struct QueryIdempotencyTokenAutoFillRequestSerializer;
  169    182   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for QueryIdempotencyTokenAutoFillRequestSerializer {
  170    183   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  171    184   
    fn serialize_input(
  172    185   
        &self,
  173    186   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  174    187   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  175    188   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  176    189   
        let input = input
  177    190   
            .downcast::<crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput>()
  178    191   
            .expect("correct type");
  179    192   
        let _header_serialization_settings = _cfg
  180    193   
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  181    194   
            .cloned()
  182    195   
            .unwrap_or_default();
  183    196   
        let mut request_builder = {
  184    197   
            fn uri_base(
  185    198   
                _input: &crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput,
  186    199   
                output: &mut ::std::string::String,
  187    200   
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  188    201   
                use ::std::fmt::Write as _;
  189    202   
                ::std::write!(output, "/").expect("formatting should succeed");
  190    203   
                ::std::result::Result::Ok(())
  191    204   
            }
  192    205   
            #[allow(clippy::unnecessary_wraps)]
  193    206   
            fn update_http_builder(
  194    207   
                input: &crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput,
  195    208   
                builder: ::http::request::Builder,
  196    209   
            ) -> ::std::result::Result<::http::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  197    210   
                let mut uri = ::std::string::String::new();
  198    211   
                uri_base(input, &mut uri)?;
  199    212   
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  200    213   
            }
  201    214   
            let mut builder = update_http_builder(&input, ::http::request::Builder::new())?;
  202    215   
            builder = _header_serialization_settings.set_default_header(builder, ::http::header::CONTENT_TYPE, "application/x-www-form-urlencoded");
  203    216   
            builder
  204    217   
        };
  205    218   
        let body = ::aws_smithy_types::body::SdkBody::from(
  206    219   
            crate::protocol_serde::shape_query_idempotency_token_auto_fill_input::ser_query_idempotency_token_auto_fill_input_input_input(&input)?,
  207    220   
        );
  208    221   
        if let Some(content_length) = body.content_length() {
  209    222   
            let content_length = content_length.to_string();
  210    223   
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http::header::CONTENT_LENGTH, &content_length);
  211    224   
        }
  212    225   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  213    226   
    }
  214    227   
}
         228  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  215    229   
#[derive(Debug)]
  216    230   
struct QueryIdempotencyTokenAutoFillEndpointParamsInterceptor;
  217    231   
  218    232   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for QueryIdempotencyTokenAutoFillEndpointParamsInterceptor {
  219    233   
    fn name(&self) -> &'static str {
  220    234   
        "QueryIdempotencyTokenAutoFillEndpointParamsInterceptor"
  221    235   
    }
  222    236   
  223    237   
    fn read_before_execution(
  224    238   
        &self,
  225    239   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  226    240   
            '_,
  227    241   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  228    242   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  229    243   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  230    244   
        >,
  231    245   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  232    246   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  233    247   
        let _input = context
  234    248   
            .input()
  235    249   
            .downcast_ref::<QueryIdempotencyTokenAutoFillInput>()
  236    250   
            .ok_or("failed to downcast to QueryIdempotencyTokenAutoFillInput")?;
  237    251   
  238    252   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  239    253   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  240    254   
        })?;
  241    255   
        cfg.interceptor_state()
  242    256   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  243    257   
        ::std::result::Result::Ok(())
  244    258   
    }
  245    259   
}
  246    260   
  247    261   
// The get_* functions below are generated from JMESPath expressions in the
  248    262   
// operationContextParams trait. They target the operation's input shape.
  249    263   
         264  +
/* RustType.kt:516 */
  250    265   
#[allow(unreachable_code, unused_variables)]
         266  +
/* RustType.kt:516 */
  251    267   
#[cfg(test)]
         268  +
/* ProtocolTestGenerator.kt:98 */
  252    269   
mod query_idempotency_token_auto_fill_test {
  253    270   
  254    271   
    /// Automatically adds idempotency token when not set
  255    272   
    /// Test ID: Ec2ProtocolIdempotencyTokenAutoFill
  256    273   
    #[::tokio::test]
  257    274   
    #[::tracing_test::traced_test]
  258    275   
    async fn ec2_protocol_idempotency_token_auto_fill_request() {
  259    276   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  260    277   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  261    278   
  262    279   
        let client = crate::Client::from_conf(config_builder.http_client(http_client).build());
  263    280   
        let result = client.query_idempotency_token_auto_fill().send().await;
  264    281   
        let _ = dbg!(result);
  265    282   
        let http_request = request_receiver.expect_request();
  266    283   
        let expected_headers = [("Content-Type", "application/x-www-form-urlencoded")];
  267    284   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(http_request.headers(), expected_headers));
  268    285   
        let required_headers = &["Content-Length"];
  269    286   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::require_headers(http_request.headers(), required_headers));
  270    287   
        let body = http_request.body().bytes().expect("body should be strict");
  271    288   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
  272    289   
            body,
  273    290   
            "Action=QueryIdempotencyTokenAutoFill&Version=2020-01-08&Token=00000000-0000-4000-8000-000000000000",
  274    291   
            ::aws_smithy_protocol_test::MediaType::from("application/x-www-form-urlencoded"),
  275    292   
        ));
  276    293   
        let uri: ::http::Uri = http_request.uri().parse().expect("invalid URI sent");
  277    294   
        ::pretty_assertions::assert_eq!(http_request.method(), "POST", "method was incorrect");
  278    295   
        ::pretty_assertions::assert_eq!(uri.path(), "/", "path was incorrect");
  279    296   
    }
  280    297   
  281    298   
    /// Uses the given idempotency token as-is
  282    299   
    /// Test ID: Ec2ProtocolIdempotencyTokenAutoFillIsSet
  283    300   
    #[::tokio::test]
  284    301   
    #[::tracing_test::traced_test]
  285    302   
    async fn ec2_protocol_idempotency_token_auto_fill_is_set_request() {
  286    303   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  287    304   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  288    305   
  289    306   
        let client = crate::Client::from_conf(config_builder.http_client(http_client).build());
  290    307   
        let result = client
  291    308   
            .query_idempotency_token_auto_fill()
  292    309   
            .set_token(::std::option::Option::Some("00000000-0000-4000-8000-000000000123".to_owned()))
  293    310   
            .send()
  294    311   
            .await;
  295    312   
        let _ = dbg!(result);
  296    313   
        let http_request = request_receiver.expect_request();
  297    314   
        let expected_headers = [("Content-Type", "application/x-www-form-urlencoded")];
  298    315   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(http_request.headers(), expected_headers));
  299    316   
        let required_headers = &["Content-Length"];
  300    317   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::require_headers(http_request.headers(), required_headers));
  301    318   
        let body = http_request.body().bytes().expect("body should be strict");
  302    319   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
  303    320   
            body,
  304    321   
            "Action=QueryIdempotencyTokenAutoFill&Version=2020-01-08&Token=00000000-0000-4000-8000-000000000123",
  305    322   
            ::aws_smithy_protocol_test::MediaType::from("application/x-www-form-urlencoded"),
  306    323   
        ));
  307    324   
        let uri: ::http::Uri = http_request.uri().parse().expect("invalid URI sent");
  308    325   
        ::pretty_assertions::assert_eq!(http_request.method(), "POST", "method was incorrect");
  309    326   
        ::pretty_assertions::assert_eq!(uri.path(), "/", "path was incorrect");
  310    327   
    }
         328  +
         329  +
    /* ProtocolTestGenerator.kt:98 */
  311    330   
}
  312    331   
         332  +
/* OperationErrorGenerator.kt:79 */
  313    333   
/// Error type for the `QueryIdempotencyTokenAutoFillError` operation.
         334  +
/* RustType.kt:516 */
  314    335   
#[non_exhaustive]
         336  +
/* RustType.kt:516 */
  315    337   
#[derive(::std::fmt::Debug)]
  316         -
pub enum QueryIdempotencyTokenAutoFillError {
         338  +
pub /* OperationErrorGenerator.kt:81 */ enum QueryIdempotencyTokenAutoFillError {
         339  +
    /* OperationErrorGenerator.kt:88 */
  317    340   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  318    341   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  319    342   
    variable wildcard pattern and check `.code()`:
  320    343   
     \
  321    344   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  322    345   
     \
  323    346   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-QueryIdempotencyTokenAutoFillError) for what information is available for the error.")]
  324    347   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         348  +
    /* OperationErrorGenerator.kt:81 */
  325    349   
}
         350  +
/* OperationErrorGenerator.kt:218 */
  326    351   
impl QueryIdempotencyTokenAutoFillError {
         352  +
    /* OperationErrorGenerator.kt:219 */
  327    353   
    /// Creates the `QueryIdempotencyTokenAutoFillError::Unhandled` variant from any error type.
  328    354   
    pub fn unhandled(
  329    355   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  330    356   
    ) -> Self {
  331    357   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  332    358   
            source: err.into(),
  333    359   
            meta: ::std::default::Default::default(),
  334    360   
        })
  335    361   
    }
  336    362   
  337    363   
    /// Creates the `QueryIdempotencyTokenAutoFillError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  338    364   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  339    365   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  340    366   
            source: err.clone().into(),
  341    367   
            meta: err,
  342    368   
        })
  343    369   
    }
  344         -
    ///
         370  +
    /// /* OperationErrorGenerator.kt:236 */
  345    371   
    /// Returns error metadata, which includes the error code, message,
  346    372   
    /// request ID, and potentially additional information.
  347    373   
    ///
         374  +
    /* OperationErrorGenerator.kt:242 */
  348    375   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         376  +
        /* OperationErrorGenerator.kt:243 */
  349    377   
        match self {
  350         -
            Self::Unhandled(e) => &e.meta,
         378  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         379  +
            /* OperationErrorGenerator.kt:243 */
  351    380   
        }
         381  +
        /* OperationErrorGenerator.kt:242 */
  352    382   
    }
         383  +
    /* OperationErrorGenerator.kt:218 */
  353    384   
}
         385  +
/* OperationErrorGenerator.kt:269 */
  354    386   
impl ::std::error::Error for QueryIdempotencyTokenAutoFillError {
         387  +
    /* OperationErrorGenerator.kt:270 */
  355    388   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         389  +
        /* OperationErrorGenerator.kt:318 */
  356    390   
        match self {
  357         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         391  +
            /* OperationErrorGenerator.kt:326 */
         392  +
            Self::Unhandled(_inner) => {
         393  +
                /* OperationErrorGenerator.kt:279 */
         394  +
                ::std::option::Option::Some(&*_inner.source)
         395  +
                /* OperationErrorGenerator.kt:326 */
         396  +
            } /* OperationErrorGenerator.kt:318 */
  358    397   
        }
         398  +
        /* OperationErrorGenerator.kt:270 */
  359    399   
    }
         400  +
    /* OperationErrorGenerator.kt:269 */
  360    401   
}
         402  +
/* OperationErrorGenerator.kt:133 */
  361    403   
impl ::std::fmt::Display for QueryIdempotencyTokenAutoFillError {
         404  +
    /* OperationErrorGenerator.kt:134 */
  362    405   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         406  +
        /* OperationErrorGenerator.kt:318 */
  363    407   
        match self {
         408  +
            /* OperationErrorGenerator.kt:326 */
  364    409   
            Self::Unhandled(_inner) => {
         410  +
                /* OperationErrorGenerator.kt:139 */
  365    411   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  366    412   
                    write!(f, "unhandled error ({code})")
  367    413   
                } else {
  368    414   
                    f.write_str("unhandled error")
  369    415   
                }
         416  +
                /* OperationErrorGenerator.kt:326 */
         417  +
            } /* OperationErrorGenerator.kt:318 */
  370    418   
        }
         419  +
        /* OperationErrorGenerator.kt:134 */
  371    420   
    }
  372         -
    }
         421  +
    /* OperationErrorGenerator.kt:133 */
  373    422   
}
         423  +
/* OperationErrorGenerator.kt:182 */
  374    424   
impl ::aws_smithy_types::retry::ProvideErrorKind for QueryIdempotencyTokenAutoFillError {
         425  +
    /* OperationErrorGenerator.kt:186 */
  375    426   
    fn code(&self) -> ::std::option::Option<&str> {
         427  +
        /* OperationErrorGenerator.kt:187 */
  376    428   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         429  +
        /* OperationErrorGenerator.kt:186 */
  377    430   
    }
         431  +
    /* OperationErrorGenerator.kt:190 */
  378    432   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         433  +
        /* OperationErrorGenerator.kt:197 */
  379    434   
        ::std::option::Option::None
         435  +
        /* OperationErrorGenerator.kt:190 */
  380    436   
    }
         437  +
    /* OperationErrorGenerator.kt:182 */
  381    438   
}
         439  +
/* OperationErrorGenerator.kt:163 */
  382    440   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for QueryIdempotencyTokenAutoFillError {
         441  +
    /* OperationErrorGenerator.kt:164 */
  383    442   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         443  +
        /* OperationErrorGenerator.kt:318 */
  384    444   
        match self {
  385         -
            Self::Unhandled(_inner) => &_inner.meta,
         445  +
            /* OperationErrorGenerator.kt:326 */
         446  +
            Self::Unhandled(_inner) => {
         447  +
                /* OperationErrorGenerator.kt:168 */
         448  +
                &_inner.meta
         449  +
                /* OperationErrorGenerator.kt:326 */
         450  +
            } /* OperationErrorGenerator.kt:318 */
  386    451   
        }
         452  +
        /* OperationErrorGenerator.kt:164 */
  387    453   
    }
         454  +
    /* OperationErrorGenerator.kt:163 */
  388    455   
}
         456  +
/* OperationErrorGenerator.kt:109 */
  389    457   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for QueryIdempotencyTokenAutoFillError {
         458  +
    /* OperationErrorGenerator.kt:110 */
  390    459   
    fn create_unhandled_error(
  391    460   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  392    461   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  393    462   
    ) -> Self {
         463  +
        /* OperationErrorGenerator.kt:121 */
  394    464   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  395    465   
            source,
  396    466   
            meta: meta.unwrap_or_default(),
  397    467   
        })
         468  +
        /* OperationErrorGenerator.kt:110 */
  398    469   
    }
         470  +
    /* OperationErrorGenerator.kt:109 */
  399    471   
}
  400    472   
         473  +
/* CodegenDelegator.kt:255 */
  401    474   
pub use crate::operation::query_idempotency_token_auto_fill::_query_idempotency_token_auto_fill_output::QueryIdempotencyTokenAutoFillOutput;
  402    475   
         476  +
/* CodegenDelegator.kt:255 */
  403    477   
pub use crate::operation::query_idempotency_token_auto_fill::_query_idempotency_token_auto_fill_input::QueryIdempotencyTokenAutoFillInput;
  404    478   
         479  +
/* RustModule.kt:172 */
  405    480   
mod _query_idempotency_token_auto_fill_input;
  406    481   
         482  +
/* RustModule.kt:172 */
  407    483   
mod _query_idempotency_token_auto_fill_output;
  408    484   
  409         -
/// Builders
         485  +
/// /* CodegenDelegator.kt:51 */Builders
  410    486   
pub mod builders;

tmp-codegen-diff/codegen-client-test/ec2_query/rust-client-codegen/src/operation/query_idempotency_token_auto_fill/_query_idempotency_token_auto_fill_input.rs

@@ -1,1 +52,96 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* StructureGenerator.kt:197 */
    2      3   
#[allow(missing_docs)] // documentation missing in model
           4  +
/* RustType.kt:516 */
    3      5   
#[non_exhaustive]
           6  +
/* RustType.kt:516 */
    4      7   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5         -
pub struct QueryIdempotencyTokenAutoFillInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct QueryIdempotencyTokenAutoFillInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub token: ::std::option::Option<::std::string::String>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl QueryIdempotencyTokenAutoFillInput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn token(&self) -> ::std::option::Option<&str> {
          20  +
        /* StructureGenerator.kt:169 */
   12     21   
        self.token.as_deref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl QueryIdempotencyTokenAutoFillInput {
   16         -
    /// Creates a new builder-style object to manufacture [`QueryIdempotencyTokenAutoFillInput`](crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`QueryIdempotencyTokenAutoFillInput`](crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::query_idempotency_token_auto_fill::builders::QueryIdempotencyTokenAutoFillInputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::query_idempotency_token_auto_fill::builders::QueryIdempotencyTokenAutoFillInputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`QueryIdempotencyTokenAutoFillInput`](crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`QueryIdempotencyTokenAutoFillInput`](crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput).
          39  +
/* RustType.kt:516 */
   23     40   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          41  +
/* RustType.kt:516 */
   24     42   
#[non_exhaustive]
          43  +
/* BuilderGenerator.kt:345 */
   25     44   
pub struct QueryIdempotencyTokenAutoFillInputBuilder {
   26         -
    pub(crate) token: ::std::option::Option<::std::string::String>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) token: ::std::option::Option<::std::string::String>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl QueryIdempotencyTokenAutoFillInputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
          52  +
                           /* BuilderGenerator.kt:291 */
   30     53   
    pub fn token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
          54  +
        /* BuilderGenerator.kt:292 */
   31     55   
        self.token = ::std::option::Option::Some(input.into());
          56  +
        /* BuilderGenerator.kt:293 */
   32     57   
        self
          58  +
        /* BuilderGenerator.kt:291 */
   33     59   
    }
          60  +
    /* BuilderGenerator.kt:312 */
   34     61   
    #[allow(missing_docs)] // documentation missing in model
          62  +
                           /* BuilderGenerator.kt:314 */
   35     63   
    pub fn set_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
          64  +
        /* BuilderGenerator.kt:315 */
   36     65   
        self.token = input;
   37     66   
        self
          67  +
        /* BuilderGenerator.kt:314 */
   38     68   
    }
          69  +
    /* BuilderGenerator.kt:334 */
   39     70   
    #[allow(missing_docs)] // documentation missing in model
          71  +
                           /* BuilderGenerator.kt:336 */
   40     72   
    pub fn get_token(&self) -> &::std::option::Option<::std::string::String> {
          73  +
        /* BuilderGenerator.kt:337 */
   41     74   
        &self.token
          75  +
        /* BuilderGenerator.kt:336 */
   42     76   
    }
   43         -
    /// Consumes the builder and constructs a [`QueryIdempotencyTokenAutoFillInput`](crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput).
          77  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`QueryIdempotencyTokenAutoFillInput`](crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput).
          78  +
    /* BuilderGenerator.kt:253 */
   44     79   
    pub fn build(
   45     80   
        self,
   46     81   
    ) -> ::std::result::Result<
   47     82   
        crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput,
   48     83   
        ::aws_smithy_types::error::operation::BuildError,
   49     84   
    > {
   50         -
        ::std::result::Result::Ok(crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput { token: self.token })
          85  +
        /* BuilderGenerator.kt:254 */
          86  +
        ::std::result::Result::Ok(
          87  +
            /* BuilderGenerator.kt:477 */
          88  +
            crate::operation::query_idempotency_token_auto_fill::QueryIdempotencyTokenAutoFillInput {
          89  +
                /* BuilderGenerator.kt:481 */ token: self.token,
          90  +
                /* BuilderGenerator.kt:477 */
          91  +
            }, /* BuilderGenerator.kt:254 */
          92  +
        )
          93  +
        /* BuilderGenerator.kt:253 */
   51     94   
    }
          95  +
    /* BuilderGenerator.kt:355 */
   52     96   
}