Client Test

Client Test

rev. dfb5149b65b7bcc09edd15b8e071ad43b5ac5943

Files changed:

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_string/_malformed_string_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 MalformedStringOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedStringOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl MalformedStringOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`MalformedStringOutput`](crate::operation::malformed_string::MalformedStringOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedStringOutput`](crate::operation::malformed_string::MalformedStringOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::malformed_string::builders::MalformedStringOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::malformed_string::builders::MalformedStringOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`MalformedStringOutput`](crate::operation::malformed_string::MalformedStringOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedStringOutput`](crate::operation::malformed_string::MalformedStringOutput).
          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 MalformedStringOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct MalformedStringOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl MalformedStringOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`MalformedStringOutput`](crate::operation::malformed_string::MalformedStringOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedStringOutput`](crate::operation::malformed_string::MalformedStringOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::malformed_string::MalformedStringOutput {
   20         -
        crate::operation::malformed_string::MalformedStringOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::malformed_string::MalformedStringOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_string/builders.rs

@@ -1,1 +124,142 @@
    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::malformed_string::_malformed_string_output::MalformedStringOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::malformed_string::_malformed_string_input::MalformedStringInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::malformed_string::builders::MalformedStringInputBuilder {
    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::malformed_string::MalformedStringOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::malformed_string::MalformedStringError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.malformed_string();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `MalformedString`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `MalformedString`.
   24     27   
///
          28  +
/* RustType.kt:516 */
   25     29   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          30  +
/* FluentBuilderGenerator.kt:270 */
   26     31   
pub struct MalformedStringFluentBuilder {
   27     32   
    handle: ::std::sync::Arc<crate::client::Handle>,
   28     33   
    inner: crate::operation::malformed_string::builders::MalformedStringInputBuilder,
   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::malformed_string::MalformedStringOutput,
   34     40   
        crate::operation::malformed_string::MalformedStringError,
   35     41   
    > for MalformedStringFluentBuilder
   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::malformed_string::MalformedStringOutput,
   43     49   
            crate::operation::malformed_string::MalformedStringError,
   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 MalformedStringFluentBuilder {
          57  +
    /* FluentBuilderGenerator.kt:288 */
   50     58   
    /// Creates a new `MalformedStringFluentBuilder`.
   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 MalformedString as a reference.
   59     68   
    pub fn as_input(&self) -> &crate::operation::malformed_string::builders::MalformedStringInputBuilder {
   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::malformed_string::MalformedStringOutput,
   74     84   
        ::aws_smithy_runtime_api::client::result::SdkError<
   75     85   
            crate::operation::malformed_string::MalformedStringError,
   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::malformed_string::MalformedString::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::malformed_string::MalformedString::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::malformed_string::MalformedStringOutput,
   96    106   
        crate::operation::malformed_string::MalformedStringError,
   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 blob(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
  112    125   
        self.inner = self.inner.blob(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_blob(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
  117    132   
        self.inner = self.inner.set_blob(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_blob(&self) -> &::std::option::Option<::std::string::String> {
  122    139   
        self.inner.get_blob()
  123    140   
    }
         141  +
    /* FluentBuilderGenerator.kt:282 */
  124    142   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_date_time.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 `MalformedTimestampBodyDateTime`.
           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 MalformedTimestampBodyDateTime;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl MalformedTimestampBodyDateTime {
    7         -
    /// Creates a new `MalformedTimestampBodyDateTime`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `MalformedTimestampBodyDateTime`
          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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -63,72 +339,410 @@
   83     92   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   84     93   
            }
   85     94   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   86     95   
                config_override,
   87     96   
                client_config.config.clone(),
   88     97   
                &client_config.runtime_components,
   89     98   
            ));
   90     99   
        }
   91    100   
        runtime_plugins
   92    101   
    }
         102  +
    /* OperationGenerator.kt:85 */
   93    103   
}
         104  +
/* OperationRuntimePluginGenerator.kt:55 */
   94    105   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for MalformedTimestampBodyDateTime {
   95    106   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   96    107   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("MalformedTimestampBodyDateTime");
   97    108   
   98    109   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   99    110   
            MalformedTimestampBodyDateTimeRequestSerializer,
  100    111   
        ));
  101    112   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  102    113   
            MalformedTimestampBodyDateTimeResponseDeserializer,
  103    114   
        ));
  104    115   
  105    116   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  106    117   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  107    118   
        ));
  108    119   
  109    120   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  110    121   
            "MalformedTimestampBodyDateTime",
  111    122   
            "Rest Json Protocol",
  112    123   
        ));
  113    124   
  114    125   
        ::std::option::Option::Some(cfg.freeze())
  115    126   
    }
  116    127   
  117    128   
    fn runtime_components(
  118    129   
        &self,
  119    130   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  120    131   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  121    132   
        #[allow(unused_mut)]
  122    133   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("MalformedTimestampBodyDateTime")
  123    134   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  124    135   
            .with_interceptor(MalformedTimestampBodyDateTimeEndpointParamsInterceptor)
  125    136   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  126    137   
                crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
  127    138   
            >::new())
  128    139   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  129    140   
                crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
  130    141   
            >::new());
  131    142   
  132    143   
        ::std::borrow::Cow::Owned(rcb)
  133    144   
    }
  134    145   
}
  135    146   
         147  +
/* ResponseDeserializerGenerator.kt:64 */
  136    148   
#[derive(Debug)]
  137    149   
struct MalformedTimestampBodyDateTimeResponseDeserializer;
  138    150   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for MalformedTimestampBodyDateTimeResponseDeserializer {
  139    151   
    fn deserialize_nonstreaming(
  140    152   
        &self,
  141    153   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  142    154   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  143    155   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  144    156   
        let headers = response.headers();
  145    157   
        let body = response.body().bytes().expect("body loaded");
  146    158   
        #[allow(unused_mut)]
  147    159   
        let mut force_error = false;
  148    160   
  149    161   
        let parse_result = if !success && status != 200 || force_error {
  150    162   
            crate::protocol_serde::shape_malformed_timestamp_body_date_time::de_malformed_timestamp_body_date_time_http_error(status, headers, body)
  151    163   
        } else {
  152    164   
            crate::protocol_serde::shape_malformed_timestamp_body_date_time::de_malformed_timestamp_body_date_time_http_response(
  153    165   
                status, headers, body,
  154    166   
            )
  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 MalformedTimestampBodyDateTimeRequestSerializer;
  161    174   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for MalformedTimestampBodyDateTimeRequestSerializer {
  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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput>()
  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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput,
  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, "/MalformedTimestampBodyDateTime").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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput,
  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/json");
  195    208   
            builder
  196    209   
        };
  197    210   
        let body = ::aws_smithy_types::body::SdkBody::from(
  198    211   
            crate::protocol_serde::shape_malformed_timestamp_body_date_time::ser_malformed_timestamp_body_date_time_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 MalformedTimestampBodyDateTimeEndpointParamsInterceptor;
  209    223   
  210    224   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for MalformedTimestampBodyDateTimeEndpointParamsInterceptor {
  211    225   
    fn name(&self) -> &'static str {
  212    226   
        "MalformedTimestampBodyDateTimeEndpointParamsInterceptor"
  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::<MalformedTimestampBodyDateTimeInput>()
  228    242   
            .ok_or("failed to downcast to MalformedTimestampBodyDateTimeInput")?;
  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  +
/* OperationErrorGenerator.kt:79 */
  242    257   
/// Error type for the `MalformedTimestampBodyDateTimeError` operation.
         258  +
/* RustType.kt:516 */
  243    259   
#[non_exhaustive]
         260  +
/* RustType.kt:516 */
  244    261   
#[derive(::std::fmt::Debug)]
  245         -
pub enum MalformedTimestampBodyDateTimeError {
         262  +
pub /* OperationErrorGenerator.kt:81 */ enum MalformedTimestampBodyDateTimeError {
         263  +
    /* OperationErrorGenerator.kt:88 */
  246    264   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  247    265   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  248    266   
    variable wildcard pattern and check `.code()`:
  249    267   
     \
  250    268   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  251    269   
     \
  252    270   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-MalformedTimestampBodyDateTimeError) for what information is available for the error.")]
  253    271   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         272  +
    /* OperationErrorGenerator.kt:81 */
  254    273   
}
         274  +
/* OperationErrorGenerator.kt:218 */
  255    275   
impl MalformedTimestampBodyDateTimeError {
         276  +
    /* OperationErrorGenerator.kt:219 */
  256    277   
    /// Creates the `MalformedTimestampBodyDateTimeError::Unhandled` variant from any error type.
  257    278   
    pub fn unhandled(
  258    279   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  259    280   
    ) -> Self {
  260    281   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  261    282   
            source: err.into(),
  262    283   
            meta: ::std::default::Default::default(),
  263    284   
        })
  264    285   
    }
  265    286   
  266    287   
    /// Creates the `MalformedTimestampBodyDateTimeError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  267    288   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  268    289   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  269    290   
            source: err.clone().into(),
  270    291   
            meta: err,
  271    292   
        })
  272    293   
    }
  273         -
    ///
         294  +
    /// /* OperationErrorGenerator.kt:236 */
  274    295   
    /// Returns error metadata, which includes the error code, message,
  275    296   
    /// request ID, and potentially additional information.
  276    297   
    ///
         298  +
    /* OperationErrorGenerator.kt:242 */
  277    299   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         300  +
        /* OperationErrorGenerator.kt:243 */
  278    301   
        match self {
  279         -
            Self::Unhandled(e) => &e.meta,
         302  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         303  +
            /* OperationErrorGenerator.kt:243 */
  280    304   
        }
         305  +
        /* OperationErrorGenerator.kt:242 */
  281    306   
    }
         307  +
    /* OperationErrorGenerator.kt:218 */
  282    308   
}
         309  +
/* OperationErrorGenerator.kt:269 */
  283    310   
impl ::std::error::Error for MalformedTimestampBodyDateTimeError {
         311  +
    /* OperationErrorGenerator.kt:270 */
  284    312   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         313  +
        /* OperationErrorGenerator.kt:318 */
  285    314   
        match self {
  286         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         315  +
            /* OperationErrorGenerator.kt:326 */
         316  +
            Self::Unhandled(_inner) => {
         317  +
                /* OperationErrorGenerator.kt:279 */
         318  +
                ::std::option::Option::Some(&*_inner.source)
         319  +
                /* OperationErrorGenerator.kt:326 */
         320  +
            } /* OperationErrorGenerator.kt:318 */
  287    321   
        }
         322  +
        /* OperationErrorGenerator.kt:270 */
  288    323   
    }
         324  +
    /* OperationErrorGenerator.kt:269 */
  289    325   
}
         326  +
/* OperationErrorGenerator.kt:133 */
  290    327   
impl ::std::fmt::Display for MalformedTimestampBodyDateTimeError {
         328  +
    /* OperationErrorGenerator.kt:134 */
  291    329   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         330  +
        /* OperationErrorGenerator.kt:318 */
  292    331   
        match self {
         332  +
            /* OperationErrorGenerator.kt:326 */
  293    333   
            Self::Unhandled(_inner) => {
         334  +
                /* OperationErrorGenerator.kt:139 */
  294    335   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  295    336   
                    write!(f, "unhandled error ({code})")
  296    337   
                } else {
  297    338   
                    f.write_str("unhandled error")
  298    339   
                }
  299         -
            }
         340  +
                /* OperationErrorGenerator.kt:326 */
         341  +
            } /* OperationErrorGenerator.kt:318 */
  300    342   
        }
         343  +
        /* OperationErrorGenerator.kt:134 */
  301    344   
    }
         345  +
    /* OperationErrorGenerator.kt:133 */
  302    346   
}
         347  +
/* OperationErrorGenerator.kt:182 */
  303    348   
impl ::aws_smithy_types::retry::ProvideErrorKind for MalformedTimestampBodyDateTimeError {
         349  +
    /* OperationErrorGenerator.kt:186 */
  304    350   
    fn code(&self) -> ::std::option::Option<&str> {
         351  +
        /* OperationErrorGenerator.kt:187 */
  305    352   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         353  +
        /* OperationErrorGenerator.kt:186 */
  306    354   
    }
         355  +
    /* OperationErrorGenerator.kt:190 */
  307    356   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         357  +
        /* OperationErrorGenerator.kt:197 */
  308    358   
        ::std::option::Option::None
         359  +
        /* OperationErrorGenerator.kt:190 */
  309    360   
    }
         361  +
    /* OperationErrorGenerator.kt:182 */
  310    362   
}
         363  +
/* OperationErrorGenerator.kt:163 */
  311    364   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for MalformedTimestampBodyDateTimeError {
         365  +
    /* OperationErrorGenerator.kt:164 */
  312    366   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         367  +
        /* OperationErrorGenerator.kt:318 */
  313    368   
        match self {
  314         -
            Self::Unhandled(_inner) => &_inner.meta,
         369  +
            /* OperationErrorGenerator.kt:326 */
         370  +
            Self::Unhandled(_inner) => {
         371  +
                /* OperationErrorGenerator.kt:168 */
         372  +
                &_inner.meta
         373  +
                /* OperationErrorGenerator.kt:326 */
         374  +
            } /* OperationErrorGenerator.kt:318 */
  315    375   
        }
         376  +
        /* OperationErrorGenerator.kt:164 */
  316    377   
    }
         378  +
    /* OperationErrorGenerator.kt:163 */
  317    379   
}
         380  +
/* OperationErrorGenerator.kt:109 */
  318    381   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for MalformedTimestampBodyDateTimeError {
         382  +
    /* OperationErrorGenerator.kt:110 */
  319    383   
    fn create_unhandled_error(
  320    384   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  321    385   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  322    386   
    ) -> Self {
         387  +
        /* OperationErrorGenerator.kt:121 */
  323    388   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  324    389   
            source,
  325    390   
            meta: meta.unwrap_or_default(),
  326    391   
        })
         392  +
        /* OperationErrorGenerator.kt:110 */
  327    393   
    }
         394  +
    /* OperationErrorGenerator.kt:109 */
  328    395   
}
  329    396   
         397  +
/* CodegenDelegator.kt:255 */
  330    398   
pub use crate::operation::malformed_timestamp_body_date_time::_malformed_timestamp_body_date_time_output::MalformedTimestampBodyDateTimeOutput;
  331    399   
         400  +
/* CodegenDelegator.kt:255 */
  332    401   
pub use crate::operation::malformed_timestamp_body_date_time::_malformed_timestamp_body_date_time_input::MalformedTimestampBodyDateTimeInput;
  333    402   
         403  +
/* RustModule.kt:172 */
  334    404   
mod _malformed_timestamp_body_date_time_input;
  335    405   
         406  +
/* RustModule.kt:172 */
  336    407   
mod _malformed_timestamp_body_date_time_output;
  337    408   
  338         -
/// Builders
         409  +
/// /* CodegenDelegator.kt:51 */Builders
  339    410   
pub mod builders;

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_date_time/_malformed_timestamp_body_date_time_input.rs

@@ -1,1 +55,97 @@
    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 MalformedTimestampBodyDateTimeInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampBodyDateTimeInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl MalformedTimestampBodyDateTimeInput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
          20  +
        /* StructureGenerator.kt:170 */
   12     21   
        self.timestamp.as_ref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl MalformedTimestampBodyDateTimeInput {
   16         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampBodyDateTimeInput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampBodyDateTimeInput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeInputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeInputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`MalformedTimestampBodyDateTimeInput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampBodyDateTimeInput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput).
          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 MalformedTimestampBodyDateTimeInputBuilder {
   26         -
    pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl MalformedTimestampBodyDateTimeInputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
   30         -
    /// This field is required.
          52  +
    /// /* BuilderGenerator.kt:288 */This field is required.
          53  +
    /* BuilderGenerator.kt:291 */
   31     54   
    pub fn timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
          55  +
        /* BuilderGenerator.kt:292 */
   32     56   
        self.timestamp = ::std::option::Option::Some(input);
          57  +
        /* BuilderGenerator.kt:293 */
   33     58   
        self
          59  +
        /* BuilderGenerator.kt:291 */
   34     60   
    }
          61  +
    /* BuilderGenerator.kt:312 */
   35     62   
    #[allow(missing_docs)] // documentation missing in model
          63  +
                           /* BuilderGenerator.kt:314 */
   36     64   
    pub fn set_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
          65  +
        /* BuilderGenerator.kt:315 */
   37     66   
        self.timestamp = input;
   38     67   
        self
          68  +
        /* BuilderGenerator.kt:314 */
   39     69   
    }
          70  +
    /* BuilderGenerator.kt:334 */
   40     71   
    #[allow(missing_docs)] // documentation missing in model
          72  +
                           /* BuilderGenerator.kt:336 */
   41     73   
    pub fn get_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
          74  +
        /* BuilderGenerator.kt:337 */
   42     75   
        &self.timestamp
          76  +
        /* BuilderGenerator.kt:336 */
   43     77   
    }
   44         -
    /// Consumes the builder and constructs a [`MalformedTimestampBodyDateTimeInput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput).
          78  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampBodyDateTimeInput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput).
          79  +
    /* BuilderGenerator.kt:253 */
   45     80   
    pub fn build(
   46     81   
        self,
   47     82   
    ) -> ::std::result::Result<
   48     83   
        crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput,
   49     84   
        ::aws_smithy_types::error::operation::BuildError,
   50     85   
    > {
          86  +
        /* BuilderGenerator.kt:254 */
   51     87   
        ::std::result::Result::Ok(
   52         -
            crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput { timestamp: self.timestamp },
          88  +
            /* BuilderGenerator.kt:477 */
          89  +
            crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeInput {
          90  +
                /* BuilderGenerator.kt:481 */ timestamp: self.timestamp,
          91  +
                /* BuilderGenerator.kt:477 */
          92  +
            }, /* BuilderGenerator.kt:254 */
   53     93   
        )
          94  +
        /* BuilderGenerator.kt:253 */
   54     95   
    }
          96  +
    /* BuilderGenerator.kt:355 */
   55     97   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_date_time/_malformed_timestamp_body_date_time_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 MalformedTimestampBodyDateTimeOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampBodyDateTimeOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl MalformedTimestampBodyDateTimeOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampBodyDateTimeOutput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampBodyDateTimeOutput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`MalformedTimestampBodyDateTimeOutput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampBodyDateTimeOutput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput).
          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 MalformedTimestampBodyDateTimeOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct MalformedTimestampBodyDateTimeOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl MalformedTimestampBodyDateTimeOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`MalformedTimestampBodyDateTimeOutput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampBodyDateTimeOutput`](crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput {
   20         -
        crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_date_time/builders.rs

@@ -1,1 +124,142 @@
    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::malformed_timestamp_body_date_time::_malformed_timestamp_body_date_time_output::MalformedTimestampBodyDateTimeOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::malformed_timestamp_body_date_time::_malformed_timestamp_body_date_time_input::MalformedTimestampBodyDateTimeInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeInputBuilder {
    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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.malformed_timestamp_body_date_time();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `MalformedTimestampBodyDateTime`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `MalformedTimestampBodyDateTime`.
   24     27   
///
          28  +
/* RustType.kt:516 */
   25     29   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          30  +
/* FluentBuilderGenerator.kt:270 */
   26     31   
pub struct MalformedTimestampBodyDateTimeFluentBuilder {
   27     32   
    handle: ::std::sync::Arc<crate::client::Handle>,
   28     33   
    inner: crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeInputBuilder,
   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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput,
   34     40   
        crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
   35     41   
    > for MalformedTimestampBodyDateTimeFluentBuilder
   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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput,
   43     49   
            crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
   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 MalformedTimestampBodyDateTimeFluentBuilder {
          57  +
    /* FluentBuilderGenerator.kt:288 */
   50     58   
    /// Creates a new `MalformedTimestampBodyDateTimeFluentBuilder`.
   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 MalformedTimestampBodyDateTime as a reference.
   59     68   
    pub fn as_input(&self) -> &crate::operation::malformed_timestamp_body_date_time::builders::MalformedTimestampBodyDateTimeInputBuilder {
   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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput,
   74     84   
        ::aws_smithy_runtime_api::client::result::SdkError<
   75     85   
            crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
   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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTime::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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTime::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::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeOutput,
   96    106   
        crate::operation::malformed_timestamp_body_date_time::MalformedTimestampBodyDateTimeError,
   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 timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
  112    125   
        self.inner = self.inner.timestamp(input);
  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_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
  117    132   
        self.inner = self.inner.set_timestamp(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_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
  122    139   
        self.inner.get_timestamp()
  123    140   
    }
         141  +
    /* FluentBuilderGenerator.kt:282 */
  124    142   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_default.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 `MalformedTimestampBodyDefault`.
           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 MalformedTimestampBodyDefault;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl MalformedTimestampBodyDefault {
    7         -
    /// Creates a new `MalformedTimestampBodyDefault`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `MalformedTimestampBodyDefault`
          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::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -63,72 +337,408 @@
   83     92   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   84     93   
            }
   85     94   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   86     95   
                config_override,
   87     96   
                client_config.config.clone(),
   88     97   
                &client_config.runtime_components,
   89     98   
            ));
   90     99   
        }
   91    100   
        runtime_plugins
   92    101   
    }
         102  +
    /* OperationGenerator.kt:85 */
   93    103   
}
         104  +
/* OperationRuntimePluginGenerator.kt:55 */
   94    105   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for MalformedTimestampBodyDefault {
   95    106   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   96    107   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("MalformedTimestampBodyDefault");
   97    108   
   98    109   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   99    110   
            MalformedTimestampBodyDefaultRequestSerializer,
  100    111   
        ));
  101    112   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  102    113   
            MalformedTimestampBodyDefaultResponseDeserializer,
  103    114   
        ));
  104    115   
  105    116   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  106    117   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  107    118   
        ));
  108    119   
  109    120   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  110    121   
            "MalformedTimestampBodyDefault",
  111    122   
            "Rest Json Protocol",
  112    123   
        ));
  113    124   
  114    125   
        ::std::option::Option::Some(cfg.freeze())
  115    126   
    }
  116    127   
  117    128   
    fn runtime_components(
  118    129   
        &self,
  119    130   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  120    131   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  121    132   
        #[allow(unused_mut)]
  122    133   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("MalformedTimestampBodyDefault")
  123    134   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  124    135   
            .with_interceptor(MalformedTimestampBodyDefaultEndpointParamsInterceptor)
  125    136   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  126    137   
                crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
  127    138   
            >::new())
  128    139   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  129    140   
                crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
  130    141   
            >::new());
  131    142   
  132    143   
        ::std::borrow::Cow::Owned(rcb)
  133    144   
    }
  134    145   
}
  135    146   
         147  +
/* ResponseDeserializerGenerator.kt:64 */
  136    148   
#[derive(Debug)]
  137    149   
struct MalformedTimestampBodyDefaultResponseDeserializer;
  138    150   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for MalformedTimestampBodyDefaultResponseDeserializer {
  139    151   
    fn deserialize_nonstreaming(
  140    152   
        &self,
  141    153   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  142    154   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  143    155   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  144    156   
        let headers = response.headers();
  145    157   
        let body = response.body().bytes().expect("body loaded");
  146    158   
        #[allow(unused_mut)]
  147    159   
        let mut force_error = false;
  148    160   
  149    161   
        let parse_result = if !success && status != 200 || force_error {
  150    162   
            crate::protocol_serde::shape_malformed_timestamp_body_default::de_malformed_timestamp_body_default_http_error(status, headers, body)
  151    163   
        } else {
  152    164   
            crate::protocol_serde::shape_malformed_timestamp_body_default::de_malformed_timestamp_body_default_http_response(status, headers, body)
  153    165   
        };
  154    166   
        crate::protocol_serde::type_erase_result(parse_result)
  155    167   
    }
  156    168   
}
         169  +
/* RequestSerializerGenerator.kt:67 */
  157    170   
#[derive(Debug)]
  158    171   
struct MalformedTimestampBodyDefaultRequestSerializer;
  159    172   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for MalformedTimestampBodyDefaultRequestSerializer {
  160    173   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  161    174   
    fn serialize_input(
  162    175   
        &self,
  163    176   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  164    177   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  165    178   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  166    179   
        let input = input
  167    180   
            .downcast::<crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput>()
  168    181   
            .expect("correct type");
  169    182   
        let _header_serialization_settings = _cfg
  170    183   
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  171    184   
            .cloned()
  172    185   
            .unwrap_or_default();
  173    186   
        let mut request_builder = {
  174    187   
            fn uri_base(
  175    188   
                _input: &crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput,
  176    189   
                output: &mut ::std::string::String,
  177    190   
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  178    191   
                use ::std::fmt::Write as _;
  179    192   
                ::std::write!(output, "/MalformedTimestampBodyDefault").expect("formatting should succeed");
  180    193   
                ::std::result::Result::Ok(())
  181    194   
            }
  182    195   
            #[allow(clippy::unnecessary_wraps)]
  183    196   
            fn update_http_builder(
  184    197   
                input: &crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput,
  185    198   
                builder: ::http::request::Builder,
  186    199   
            ) -> ::std::result::Result<::http::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  187    200   
                let mut uri = ::std::string::String::new();
  188    201   
                uri_base(input, &mut uri)?;
  189    202   
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  190    203   
            }
  191    204   
            let mut builder = update_http_builder(&input, ::http::request::Builder::new())?;
  192    205   
            builder = _header_serialization_settings.set_default_header(builder, ::http::header::CONTENT_TYPE, "application/json");
  193    206   
            builder
  194    207   
        };
  195    208   
        let body = ::aws_smithy_types::body::SdkBody::from(
  196    209   
            crate::protocol_serde::shape_malformed_timestamp_body_default::ser_malformed_timestamp_body_default_input(&input)?,
  197    210   
        );
  198    211   
        if let Some(content_length) = body.content_length() {
  199    212   
            let content_length = content_length.to_string();
  200    213   
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http::header::CONTENT_LENGTH, &content_length);
  201    214   
        }
  202    215   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  203    216   
    }
  204    217   
}
         218  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  205    219   
#[derive(Debug)]
  206    220   
struct MalformedTimestampBodyDefaultEndpointParamsInterceptor;
  207    221   
  208    222   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for MalformedTimestampBodyDefaultEndpointParamsInterceptor {
  209    223   
    fn name(&self) -> &'static str {
  210    224   
        "MalformedTimestampBodyDefaultEndpointParamsInterceptor"
  211    225   
    }
  212    226   
  213    227   
    fn read_before_execution(
  214    228   
        &self,
  215    229   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  216    230   
            '_,
  217    231   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  218    232   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  219    233   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  220    234   
        >,
  221    235   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  222    236   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  223    237   
        let _input = context
  224    238   
            .input()
  225    239   
            .downcast_ref::<MalformedTimestampBodyDefaultInput>()
  226    240   
            .ok_or("failed to downcast to MalformedTimestampBodyDefaultInput")?;
  227    241   
  228    242   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  229    243   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  230    244   
        })?;
  231    245   
        cfg.interceptor_state()
  232    246   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  233    247   
        ::std::result::Result::Ok(())
  234    248   
    }
  235    249   
}
  236    250   
  237    251   
// The get_* functions below are generated from JMESPath expressions in the
  238    252   
// operationContextParams trait. They target the operation's input shape.
  239    253   
         254  +
/* OperationErrorGenerator.kt:79 */
  240    255   
/// Error type for the `MalformedTimestampBodyDefaultError` operation.
         256  +
/* RustType.kt:516 */
  241    257   
#[non_exhaustive]
         258  +
/* RustType.kt:516 */
  242    259   
#[derive(::std::fmt::Debug)]
  243         -
pub enum MalformedTimestampBodyDefaultError {
         260  +
pub /* OperationErrorGenerator.kt:81 */ enum MalformedTimestampBodyDefaultError {
         261  +
    /* OperationErrorGenerator.kt:88 */
  244    262   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  245    263   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  246    264   
    variable wildcard pattern and check `.code()`:
  247    265   
     \
  248    266   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  249    267   
     \
  250    268   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-MalformedTimestampBodyDefaultError) for what information is available for the error.")]
  251    269   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         270  +
    /* OperationErrorGenerator.kt:81 */
  252    271   
}
         272  +
/* OperationErrorGenerator.kt:218 */
  253    273   
impl MalformedTimestampBodyDefaultError {
         274  +
    /* OperationErrorGenerator.kt:219 */
  254    275   
    /// Creates the `MalformedTimestampBodyDefaultError::Unhandled` variant from any error type.
  255    276   
    pub fn unhandled(
  256    277   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  257    278   
    ) -> Self {
  258    279   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  259    280   
            source: err.into(),
  260    281   
            meta: ::std::default::Default::default(),
  261    282   
        })
  262    283   
    }
  263    284   
  264    285   
    /// Creates the `MalformedTimestampBodyDefaultError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  265    286   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  266    287   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  267    288   
            source: err.clone().into(),
  268    289   
            meta: err,
  269    290   
        })
  270    291   
    }
  271         -
    ///
         292  +
    /// /* OperationErrorGenerator.kt:236 */
  272    293   
    /// Returns error metadata, which includes the error code, message,
  273    294   
    /// request ID, and potentially additional information.
  274    295   
    ///
         296  +
    /* OperationErrorGenerator.kt:242 */
  275    297   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         298  +
        /* OperationErrorGenerator.kt:243 */
  276    299   
        match self {
  277         -
            Self::Unhandled(e) => &e.meta,
         300  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         301  +
            /* OperationErrorGenerator.kt:243 */
  278    302   
        }
         303  +
        /* OperationErrorGenerator.kt:242 */
  279    304   
    }
         305  +
    /* OperationErrorGenerator.kt:218 */
  280    306   
}
         307  +
/* OperationErrorGenerator.kt:269 */
  281    308   
impl ::std::error::Error for MalformedTimestampBodyDefaultError {
         309  +
    /* OperationErrorGenerator.kt:270 */
  282    310   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         311  +
        /* OperationErrorGenerator.kt:318 */
  283    312   
        match self {
  284         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         313  +
            /* OperationErrorGenerator.kt:326 */
         314  +
            Self::Unhandled(_inner) => {
         315  +
                /* OperationErrorGenerator.kt:279 */
         316  +
                ::std::option::Option::Some(&*_inner.source)
         317  +
                /* OperationErrorGenerator.kt:326 */
         318  +
            } /* OperationErrorGenerator.kt:318 */
  285    319   
        }
         320  +
        /* OperationErrorGenerator.kt:270 */
  286    321   
    }
         322  +
    /* OperationErrorGenerator.kt:269 */
  287    323   
}
         324  +
/* OperationErrorGenerator.kt:133 */
  288    325   
impl ::std::fmt::Display for MalformedTimestampBodyDefaultError {
         326  +
    /* OperationErrorGenerator.kt:134 */
  289    327   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         328  +
        /* OperationErrorGenerator.kt:318 */
  290    329   
        match self {
         330  +
            /* OperationErrorGenerator.kt:326 */
  291    331   
            Self::Unhandled(_inner) => {
         332  +
                /* OperationErrorGenerator.kt:139 */
  292    333   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  293    334   
                    write!(f, "unhandled error ({code})")
  294    335   
                } else {
  295    336   
                    f.write_str("unhandled error")
  296    337   
                }
  297         -
            }
         338  +
                /* OperationErrorGenerator.kt:326 */
         339  +
            } /* OperationErrorGenerator.kt:318 */
  298    340   
        }
         341  +
        /* OperationErrorGenerator.kt:134 */
  299    342   
    }
         343  +
    /* OperationErrorGenerator.kt:133 */
  300    344   
}
         345  +
/* OperationErrorGenerator.kt:182 */
  301    346   
impl ::aws_smithy_types::retry::ProvideErrorKind for MalformedTimestampBodyDefaultError {
         347  +
    /* OperationErrorGenerator.kt:186 */
  302    348   
    fn code(&self) -> ::std::option::Option<&str> {
         349  +
        /* OperationErrorGenerator.kt:187 */
  303    350   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         351  +
        /* OperationErrorGenerator.kt:186 */
  304    352   
    }
         353  +
    /* OperationErrorGenerator.kt:190 */
  305    354   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         355  +
        /* OperationErrorGenerator.kt:197 */
  306    356   
        ::std::option::Option::None
         357  +
        /* OperationErrorGenerator.kt:190 */
  307    358   
    }
         359  +
    /* OperationErrorGenerator.kt:182 */
  308    360   
}
         361  +
/* OperationErrorGenerator.kt:163 */
  309    362   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for MalformedTimestampBodyDefaultError {
         363  +
    /* OperationErrorGenerator.kt:164 */
  310    364   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         365  +
        /* OperationErrorGenerator.kt:318 */
  311    366   
        match self {
  312         -
            Self::Unhandled(_inner) => &_inner.meta,
         367  +
            /* OperationErrorGenerator.kt:326 */
         368  +
            Self::Unhandled(_inner) => {
         369  +
                /* OperationErrorGenerator.kt:168 */
         370  +
                &_inner.meta
         371  +
                /* OperationErrorGenerator.kt:326 */
         372  +
            } /* OperationErrorGenerator.kt:318 */
  313    373   
        }
         374  +
        /* OperationErrorGenerator.kt:164 */
  314    375   
    }
         376  +
    /* OperationErrorGenerator.kt:163 */
  315    377   
}
         378  +
/* OperationErrorGenerator.kt:109 */
  316    379   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for MalformedTimestampBodyDefaultError {
         380  +
    /* OperationErrorGenerator.kt:110 */
  317    381   
    fn create_unhandled_error(
  318    382   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  319    383   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  320    384   
    ) -> Self {
         385  +
        /* OperationErrorGenerator.kt:121 */
  321    386   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  322    387   
            source,
  323    388   
            meta: meta.unwrap_or_default(),
  324    389   
        })
         390  +
        /* OperationErrorGenerator.kt:110 */
  325    391   
    }
         392  +
    /* OperationErrorGenerator.kt:109 */
  326    393   
}
  327    394   
         395  +
/* CodegenDelegator.kt:255 */
  328    396   
pub use crate::operation::malformed_timestamp_body_default::_malformed_timestamp_body_default_output::MalformedTimestampBodyDefaultOutput;
  329    397   
         398  +
/* CodegenDelegator.kt:255 */
  330    399   
pub use crate::operation::malformed_timestamp_body_default::_malformed_timestamp_body_default_input::MalformedTimestampBodyDefaultInput;
  331    400   
         401  +
/* RustModule.kt:172 */
  332    402   
mod _malformed_timestamp_body_default_input;
  333    403   
         404  +
/* RustModule.kt:172 */
  334    405   
mod _malformed_timestamp_body_default_output;
  335    406   
  336         -
/// Builders
         407  +
/// /* CodegenDelegator.kt:51 */Builders
  337    408   
pub mod builders;

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_default/_malformed_timestamp_body_default_input.rs

@@ -1,1 +55,97 @@
    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 MalformedTimestampBodyDefaultInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampBodyDefaultInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl MalformedTimestampBodyDefaultInput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
          20  +
        /* StructureGenerator.kt:170 */
   12     21   
        self.timestamp.as_ref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl MalformedTimestampBodyDefaultInput {
   16         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampBodyDefaultInput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampBodyDefaultInput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultInputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultInputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`MalformedTimestampBodyDefaultInput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampBodyDefaultInput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput).
          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 MalformedTimestampBodyDefaultInputBuilder {
   26         -
    pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl MalformedTimestampBodyDefaultInputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
   30         -
    /// This field is required.
          52  +
    /// /* BuilderGenerator.kt:288 */This field is required.
          53  +
    /* BuilderGenerator.kt:291 */
   31     54   
    pub fn timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
          55  +
        /* BuilderGenerator.kt:292 */
   32     56   
        self.timestamp = ::std::option::Option::Some(input);
          57  +
        /* BuilderGenerator.kt:293 */
   33     58   
        self
          59  +
        /* BuilderGenerator.kt:291 */
   34     60   
    }
          61  +
    /* BuilderGenerator.kt:312 */
   35     62   
    #[allow(missing_docs)] // documentation missing in model
          63  +
                           /* BuilderGenerator.kt:314 */
   36     64   
    pub fn set_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
          65  +
        /* BuilderGenerator.kt:315 */
   37     66   
        self.timestamp = input;
   38     67   
        self
          68  +
        /* BuilderGenerator.kt:314 */
   39     69   
    }
          70  +
    /* BuilderGenerator.kt:334 */
   40     71   
    #[allow(missing_docs)] // documentation missing in model
          72  +
                           /* BuilderGenerator.kt:336 */
   41     73   
    pub fn get_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
          74  +
        /* BuilderGenerator.kt:337 */
   42     75   
        &self.timestamp
          76  +
        /* BuilderGenerator.kt:336 */
   43     77   
    }
   44         -
    /// Consumes the builder and constructs a [`MalformedTimestampBodyDefaultInput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput).
          78  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampBodyDefaultInput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput).
          79  +
    /* BuilderGenerator.kt:253 */
   45     80   
    pub fn build(
   46     81   
        self,
   47     82   
    ) -> ::std::result::Result<
   48     83   
        crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput,
   49     84   
        ::aws_smithy_types::error::operation::BuildError,
   50     85   
    > {
   51         -
        ::std::result::Result::Ok(crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput {
   52         -
            timestamp: self.timestamp,
   53         -
        })
          86  +
        /* BuilderGenerator.kt:254 */
          87  +
        ::std::result::Result::Ok(
          88  +
            /* BuilderGenerator.kt:477 */
          89  +
            crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultInput {
          90  +
                /* BuilderGenerator.kt:481 */ timestamp: self.timestamp,
          91  +
                /* BuilderGenerator.kt:477 */
          92  +
            }, /* BuilderGenerator.kt:254 */
          93  +
        )
          94  +
        /* BuilderGenerator.kt:253 */
   54     95   
    }
          96  +
    /* BuilderGenerator.kt:355 */
   55     97   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_default/_malformed_timestamp_body_default_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 MalformedTimestampBodyDefaultOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampBodyDefaultOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl MalformedTimestampBodyDefaultOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampBodyDefaultOutput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampBodyDefaultOutput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`MalformedTimestampBodyDefaultOutput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampBodyDefaultOutput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput).
          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 MalformedTimestampBodyDefaultOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct MalformedTimestampBodyDefaultOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl MalformedTimestampBodyDefaultOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`MalformedTimestampBodyDefaultOutput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampBodyDefaultOutput`](crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput {
   20         -
        crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_default/builders.rs

@@ -1,1 +124,142 @@
    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::malformed_timestamp_body_default::_malformed_timestamp_body_default_output::MalformedTimestampBodyDefaultOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::malformed_timestamp_body_default::_malformed_timestamp_body_default_input::MalformedTimestampBodyDefaultInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultInputBuilder {
    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::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.malformed_timestamp_body_default();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `MalformedTimestampBodyDefault`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `MalformedTimestampBodyDefault`.
   24     27   
///
          28  +
/* RustType.kt:516 */
   25     29   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          30  +
/* FluentBuilderGenerator.kt:270 */
   26     31   
pub struct MalformedTimestampBodyDefaultFluentBuilder {
   27     32   
    handle: ::std::sync::Arc<crate::client::Handle>,
   28     33   
    inner: crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultInputBuilder,
   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::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput,
   34     40   
        crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
   35     41   
    > for MalformedTimestampBodyDefaultFluentBuilder
   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::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput,
   43     49   
            crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
   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 MalformedTimestampBodyDefaultFluentBuilder {
          57  +
    /* FluentBuilderGenerator.kt:288 */
   50     58   
    /// Creates a new `MalformedTimestampBodyDefaultFluentBuilder`.
   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 MalformedTimestampBodyDefault as a reference.
   59     68   
    pub fn as_input(&self) -> &crate::operation::malformed_timestamp_body_default::builders::MalformedTimestampBodyDefaultInputBuilder {
   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::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput,
   74     84   
        ::aws_smithy_runtime_api::client::result::SdkError<
   75     85   
            crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
   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::malformed_timestamp_body_default::MalformedTimestampBodyDefault::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::malformed_timestamp_body_default::MalformedTimestampBodyDefault::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::malformed_timestamp_body_default::MalformedTimestampBodyDefaultOutput,
   96    106   
        crate::operation::malformed_timestamp_body_default::MalformedTimestampBodyDefaultError,
   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 timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
  112    125   
        self.inner = self.inner.timestamp(input);
  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_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
  117    132   
        self.inner = self.inner.set_timestamp(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_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
  122    139   
        self.inner.get_timestamp()
  123    140   
    }
         141  +
    /* FluentBuilderGenerator.kt:282 */
  124    142   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_http_date.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 `MalformedTimestampBodyHttpDate`.
           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 MalformedTimestampBodyHttpDate;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl MalformedTimestampBodyHttpDate {
    7         -
    /// Creates a new `MalformedTimestampBodyHttpDate`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `MalformedTimestampBodyHttpDate`
          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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -63,72 +339,410 @@
   83     92   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   84     93   
            }
   85     94   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   86     95   
                config_override,
   87     96   
                client_config.config.clone(),
   88     97   
                &client_config.runtime_components,
   89     98   
            ));
   90     99   
        }
   91    100   
        runtime_plugins
   92    101   
    }
         102  +
    /* OperationGenerator.kt:85 */
   93    103   
}
         104  +
/* OperationRuntimePluginGenerator.kt:55 */
   94    105   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for MalformedTimestampBodyHttpDate {
   95    106   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   96    107   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("MalformedTimestampBodyHttpDate");
   97    108   
   98    109   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   99    110   
            MalformedTimestampBodyHttpDateRequestSerializer,
  100    111   
        ));
  101    112   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  102    113   
            MalformedTimestampBodyHttpDateResponseDeserializer,
  103    114   
        ));
  104    115   
  105    116   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  106    117   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  107    118   
        ));
  108    119   
  109    120   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  110    121   
            "MalformedTimestampBodyHttpDate",
  111    122   
            "Rest Json Protocol",
  112    123   
        ));
  113    124   
  114    125   
        ::std::option::Option::Some(cfg.freeze())
  115    126   
    }
  116    127   
  117    128   
    fn runtime_components(
  118    129   
        &self,
  119    130   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  120    131   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  121    132   
        #[allow(unused_mut)]
  122    133   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("MalformedTimestampBodyHttpDate")
  123    134   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  124    135   
            .with_interceptor(MalformedTimestampBodyHttpDateEndpointParamsInterceptor)
  125    136   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  126    137   
                crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
  127    138   
            >::new())
  128    139   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  129    140   
                crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
  130    141   
            >::new());
  131    142   
  132    143   
        ::std::borrow::Cow::Owned(rcb)
  133    144   
    }
  134    145   
}
  135    146   
         147  +
/* ResponseDeserializerGenerator.kt:64 */
  136    148   
#[derive(Debug)]
  137    149   
struct MalformedTimestampBodyHttpDateResponseDeserializer;
  138    150   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for MalformedTimestampBodyHttpDateResponseDeserializer {
  139    151   
    fn deserialize_nonstreaming(
  140    152   
        &self,
  141    153   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  142    154   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  143    155   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  144    156   
        let headers = response.headers();
  145    157   
        let body = response.body().bytes().expect("body loaded");
  146    158   
        #[allow(unused_mut)]
  147    159   
        let mut force_error = false;
  148    160   
  149    161   
        let parse_result = if !success && status != 200 || force_error {
  150    162   
            crate::protocol_serde::shape_malformed_timestamp_body_http_date::de_malformed_timestamp_body_http_date_http_error(status, headers, body)
  151    163   
        } else {
  152    164   
            crate::protocol_serde::shape_malformed_timestamp_body_http_date::de_malformed_timestamp_body_http_date_http_response(
  153    165   
                status, headers, body,
  154    166   
            )
  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 MalformedTimestampBodyHttpDateRequestSerializer;
  161    174   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for MalformedTimestampBodyHttpDateRequestSerializer {
  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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput>()
  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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput,
  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, "/MalformedTimestampBodyHttpDate").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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput,
  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/json");
  195    208   
            builder
  196    209   
        };
  197    210   
        let body = ::aws_smithy_types::body::SdkBody::from(
  198    211   
            crate::protocol_serde::shape_malformed_timestamp_body_http_date::ser_malformed_timestamp_body_http_date_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 MalformedTimestampBodyHttpDateEndpointParamsInterceptor;
  209    223   
  210    224   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for MalformedTimestampBodyHttpDateEndpointParamsInterceptor {
  211    225   
    fn name(&self) -> &'static str {
  212    226   
        "MalformedTimestampBodyHttpDateEndpointParamsInterceptor"
  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::<MalformedTimestampBodyHttpDateInput>()
  228    242   
            .ok_or("failed to downcast to MalformedTimestampBodyHttpDateInput")?;
  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  +
/* OperationErrorGenerator.kt:79 */
  242    257   
/// Error type for the `MalformedTimestampBodyHttpDateError` operation.
         258  +
/* RustType.kt:516 */
  243    259   
#[non_exhaustive]
         260  +
/* RustType.kt:516 */
  244    261   
#[derive(::std::fmt::Debug)]
  245         -
pub enum MalformedTimestampBodyHttpDateError {
         262  +
pub /* OperationErrorGenerator.kt:81 */ enum MalformedTimestampBodyHttpDateError {
         263  +
    /* OperationErrorGenerator.kt:88 */
  246    264   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  247    265   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  248    266   
    variable wildcard pattern and check `.code()`:
  249    267   
     \
  250    268   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  251    269   
     \
  252    270   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-MalformedTimestampBodyHttpDateError) for what information is available for the error.")]
  253    271   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         272  +
    /* OperationErrorGenerator.kt:81 */
  254    273   
}
         274  +
/* OperationErrorGenerator.kt:218 */
  255    275   
impl MalformedTimestampBodyHttpDateError {
         276  +
    /* OperationErrorGenerator.kt:219 */
  256    277   
    /// Creates the `MalformedTimestampBodyHttpDateError::Unhandled` variant from any error type.
  257    278   
    pub fn unhandled(
  258    279   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  259    280   
    ) -> Self {
  260    281   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  261    282   
            source: err.into(),
  262    283   
            meta: ::std::default::Default::default(),
  263    284   
        })
  264    285   
    }
  265    286   
  266    287   
    /// Creates the `MalformedTimestampBodyHttpDateError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  267    288   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  268    289   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  269    290   
            source: err.clone().into(),
  270    291   
            meta: err,
  271    292   
        })
  272    293   
    }
  273         -
    ///
         294  +
    /// /* OperationErrorGenerator.kt:236 */
  274    295   
    /// Returns error metadata, which includes the error code, message,
  275    296   
    /// request ID, and potentially additional information.
  276    297   
    ///
         298  +
    /* OperationErrorGenerator.kt:242 */
  277    299   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         300  +
        /* OperationErrorGenerator.kt:243 */
  278    301   
        match self {
  279         -
            Self::Unhandled(e) => &e.meta,
         302  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         303  +
            /* OperationErrorGenerator.kt:243 */
  280    304   
        }
         305  +
        /* OperationErrorGenerator.kt:242 */
  281    306   
    }
         307  +
    /* OperationErrorGenerator.kt:218 */
  282    308   
}
         309  +
/* OperationErrorGenerator.kt:269 */
  283    310   
impl ::std::error::Error for MalformedTimestampBodyHttpDateError {
         311  +
    /* OperationErrorGenerator.kt:270 */
  284    312   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         313  +
        /* OperationErrorGenerator.kt:318 */
  285    314   
        match self {
  286         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         315  +
            /* OperationErrorGenerator.kt:326 */
         316  +
            Self::Unhandled(_inner) => {
         317  +
                /* OperationErrorGenerator.kt:279 */
         318  +
                ::std::option::Option::Some(&*_inner.source)
         319  +
                /* OperationErrorGenerator.kt:326 */
         320  +
            } /* OperationErrorGenerator.kt:318 */
  287    321   
        }
         322  +
        /* OperationErrorGenerator.kt:270 */
  288    323   
    }
         324  +
    /* OperationErrorGenerator.kt:269 */
  289    325   
}
         326  +
/* OperationErrorGenerator.kt:133 */
  290    327   
impl ::std::fmt::Display for MalformedTimestampBodyHttpDateError {
         328  +
    /* OperationErrorGenerator.kt:134 */
  291    329   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         330  +
        /* OperationErrorGenerator.kt:318 */
  292    331   
        match self {
         332  +
            /* OperationErrorGenerator.kt:326 */
  293    333   
            Self::Unhandled(_inner) => {
         334  +
                /* OperationErrorGenerator.kt:139 */
  294    335   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  295    336   
                    write!(f, "unhandled error ({code})")
  296    337   
                } else {
  297    338   
                    f.write_str("unhandled error")
  298    339   
                }
  299         -
            }
         340  +
                /* OperationErrorGenerator.kt:326 */
         341  +
            } /* OperationErrorGenerator.kt:318 */
  300    342   
        }
         343  +
        /* OperationErrorGenerator.kt:134 */
  301    344   
    }
         345  +
    /* OperationErrorGenerator.kt:133 */
  302    346   
}
         347  +
/* OperationErrorGenerator.kt:182 */
  303    348   
impl ::aws_smithy_types::retry::ProvideErrorKind for MalformedTimestampBodyHttpDateError {
         349  +
    /* OperationErrorGenerator.kt:186 */
  304    350   
    fn code(&self) -> ::std::option::Option<&str> {
         351  +
        /* OperationErrorGenerator.kt:187 */
  305    352   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         353  +
        /* OperationErrorGenerator.kt:186 */
  306    354   
    }
         355  +
    /* OperationErrorGenerator.kt:190 */
  307    356   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         357  +
        /* OperationErrorGenerator.kt:197 */
  308    358   
        ::std::option::Option::None
         359  +
        /* OperationErrorGenerator.kt:190 */
  309    360   
    }
         361  +
    /* OperationErrorGenerator.kt:182 */
  310    362   
}
         363  +
/* OperationErrorGenerator.kt:163 */
  311    364   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for MalformedTimestampBodyHttpDateError {
         365  +
    /* OperationErrorGenerator.kt:164 */
  312    366   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         367  +
        /* OperationErrorGenerator.kt:318 */
  313    368   
        match self {
  314         -
            Self::Unhandled(_inner) => &_inner.meta,
         369  +
            /* OperationErrorGenerator.kt:326 */
         370  +
            Self::Unhandled(_inner) => {
         371  +
                /* OperationErrorGenerator.kt:168 */
         372  +
                &_inner.meta
         373  +
                /* OperationErrorGenerator.kt:326 */
         374  +
            } /* OperationErrorGenerator.kt:318 */
  315    375   
        }
         376  +
        /* OperationErrorGenerator.kt:164 */
  316    377   
    }
         378  +
    /* OperationErrorGenerator.kt:163 */
  317    379   
}
         380  +
/* OperationErrorGenerator.kt:109 */
  318    381   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for MalformedTimestampBodyHttpDateError {
         382  +
    /* OperationErrorGenerator.kt:110 */
  319    383   
    fn create_unhandled_error(
  320    384   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  321    385   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  322    386   
    ) -> Self {
         387  +
        /* OperationErrorGenerator.kt:121 */
  323    388   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  324    389   
            source,
  325    390   
            meta: meta.unwrap_or_default(),
  326    391   
        })
         392  +
        /* OperationErrorGenerator.kt:110 */
  327    393   
    }
         394  +
    /* OperationErrorGenerator.kt:109 */
  328    395   
}
  329    396   
         397  +
/* CodegenDelegator.kt:255 */
  330    398   
pub use crate::operation::malformed_timestamp_body_http_date::_malformed_timestamp_body_http_date_output::MalformedTimestampBodyHttpDateOutput;
  331    399   
         400  +
/* CodegenDelegator.kt:255 */
  332    401   
pub use crate::operation::malformed_timestamp_body_http_date::_malformed_timestamp_body_http_date_input::MalformedTimestampBodyHttpDateInput;
  333    402   
         403  +
/* RustModule.kt:172 */
  334    404   
mod _malformed_timestamp_body_http_date_input;
  335    405   
         406  +
/* RustModule.kt:172 */
  336    407   
mod _malformed_timestamp_body_http_date_output;
  337    408   
  338         -
/// Builders
         409  +
/// /* CodegenDelegator.kt:51 */Builders
  339    410   
pub mod builders;

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_http_date/_malformed_timestamp_body_http_date_input.rs

@@ -1,1 +55,97 @@
    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 MalformedTimestampBodyHttpDateInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampBodyHttpDateInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl MalformedTimestampBodyHttpDateInput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
          20  +
        /* StructureGenerator.kt:170 */
   12     21   
        self.timestamp.as_ref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl MalformedTimestampBodyHttpDateInput {
   16         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampBodyHttpDateInput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampBodyHttpDateInput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateInputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateInputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`MalformedTimestampBodyHttpDateInput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampBodyHttpDateInput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput).
          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 MalformedTimestampBodyHttpDateInputBuilder {
   26         -
    pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl MalformedTimestampBodyHttpDateInputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
   30         -
    /// This field is required.
          52  +
    /// /* BuilderGenerator.kt:288 */This field is required.
          53  +
    /* BuilderGenerator.kt:291 */
   31     54   
    pub fn timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
          55  +
        /* BuilderGenerator.kt:292 */
   32     56   
        self.timestamp = ::std::option::Option::Some(input);
          57  +
        /* BuilderGenerator.kt:293 */
   33     58   
        self
          59  +
        /* BuilderGenerator.kt:291 */
   34     60   
    }
          61  +
    /* BuilderGenerator.kt:312 */
   35     62   
    #[allow(missing_docs)] // documentation missing in model
          63  +
                           /* BuilderGenerator.kt:314 */
   36     64   
    pub fn set_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
          65  +
        /* BuilderGenerator.kt:315 */
   37     66   
        self.timestamp = input;
   38     67   
        self
          68  +
        /* BuilderGenerator.kt:314 */
   39     69   
    }
          70  +
    /* BuilderGenerator.kt:334 */
   40     71   
    #[allow(missing_docs)] // documentation missing in model
          72  +
                           /* BuilderGenerator.kt:336 */
   41     73   
    pub fn get_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
          74  +
        /* BuilderGenerator.kt:337 */
   42     75   
        &self.timestamp
          76  +
        /* BuilderGenerator.kt:336 */
   43     77   
    }
   44         -
    /// Consumes the builder and constructs a [`MalformedTimestampBodyHttpDateInput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput).
          78  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampBodyHttpDateInput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput).
          79  +
    /* BuilderGenerator.kt:253 */
   45     80   
    pub fn build(
   46     81   
        self,
   47     82   
    ) -> ::std::result::Result<
   48     83   
        crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput,
   49     84   
        ::aws_smithy_types::error::operation::BuildError,
   50     85   
    > {
          86  +
        /* BuilderGenerator.kt:254 */
   51     87   
        ::std::result::Result::Ok(
   52         -
            crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput { timestamp: self.timestamp },
          88  +
            /* BuilderGenerator.kt:477 */
          89  +
            crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateInput {
          90  +
                /* BuilderGenerator.kt:481 */ timestamp: self.timestamp,
          91  +
                /* BuilderGenerator.kt:477 */
          92  +
            }, /* BuilderGenerator.kt:254 */
   53     93   
        )
          94  +
        /* BuilderGenerator.kt:253 */
   54     95   
    }
          96  +
    /* BuilderGenerator.kt:355 */
   55     97   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_http_date/_malformed_timestamp_body_http_date_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 MalformedTimestampBodyHttpDateOutput {}
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampBodyHttpDateOutput {/* StructureGenerator.kt:201 */}
           9  +
/* ClientCodegenVisitor.kt:237 */
    6     10   
impl MalformedTimestampBodyHttpDateOutput {
    7         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampBodyHttpDateOutput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput).
          11  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampBodyHttpDateOutput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput).
          12  +
    /* BuilderGenerator.kt:175 */
    8     13   
    pub fn builder() -> crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateOutputBuilder {
          14  +
        /* BuilderGenerator.kt:176 */
    9     15   
        crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateOutputBuilder::default()
          16  +
        /* BuilderGenerator.kt:175 */
   10     17   
    }
          18  +
    /* ClientCodegenVisitor.kt:237 */
   11     19   
}
   12     20   
   13         -
/// A builder for [`MalformedTimestampBodyHttpDateOutput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput).
          21  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampBodyHttpDateOutput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput).
          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 MalformedTimestampBodyHttpDateOutputBuilder {}
          26  +
/* BuilderGenerator.kt:345 */
          27  +
pub struct MalformedTimestampBodyHttpDateOutputBuilder {/* BuilderGenerator.kt:345 */}
          28  +
/* BuilderGenerator.kt:355 */
   17     29   
impl MalformedTimestampBodyHttpDateOutputBuilder {
   18         -
    /// Consumes the builder and constructs a [`MalformedTimestampBodyHttpDateOutput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput).
          30  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampBodyHttpDateOutput`](crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput).
          31  +
    /* BuilderGenerator.kt:253 */
   19     32   
    pub fn build(self) -> crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput {
   20         -
        crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput {}
          33  +
        /* BuilderGenerator.kt:477 */
          34  +
        crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput {
          35  +
        /* BuilderGenerator.kt:477 */}
          36  +
        /* BuilderGenerator.kt:253 */
   21     37   
    }
          38  +
    /* BuilderGenerator.kt:355 */
   22     39   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_body_http_date/builders.rs

@@ -1,1 +124,142 @@
    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::malformed_timestamp_body_http_date::_malformed_timestamp_body_http_date_output::MalformedTimestampBodyHttpDateOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::malformed_timestamp_body_http_date::_malformed_timestamp_body_http_date_input::MalformedTimestampBodyHttpDateInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateInputBuilder {
    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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.malformed_timestamp_body_http_date();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `MalformedTimestampBodyHttpDate`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `MalformedTimestampBodyHttpDate`.
   24     27   
///
          28  +
/* RustType.kt:516 */
   25     29   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          30  +
/* FluentBuilderGenerator.kt:270 */
   26     31   
pub struct MalformedTimestampBodyHttpDateFluentBuilder {
   27     32   
    handle: ::std::sync::Arc<crate::client::Handle>,
   28     33   
    inner: crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateInputBuilder,
   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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput,
   34     40   
        crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
   35     41   
    > for MalformedTimestampBodyHttpDateFluentBuilder
   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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput,
   43     49   
            crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
   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 MalformedTimestampBodyHttpDateFluentBuilder {
          57  +
    /* FluentBuilderGenerator.kt:288 */
   50     58   
    /// Creates a new `MalformedTimestampBodyHttpDateFluentBuilder`.
   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 MalformedTimestampBodyHttpDate as a reference.
   59     68   
    pub fn as_input(&self) -> &crate::operation::malformed_timestamp_body_http_date::builders::MalformedTimestampBodyHttpDateInputBuilder {
   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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput,
   74     84   
        ::aws_smithy_runtime_api::client::result::SdkError<
   75     85   
            crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
   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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDate::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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDate::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::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateOutput,
   96    106   
        crate::operation::malformed_timestamp_body_http_date::MalformedTimestampBodyHttpDateError,
   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 timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
  112    125   
        self.inner = self.inner.timestamp(input);
  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_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
  117    132   
        self.inner = self.inner.set_timestamp(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_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
  122    139   
        self.inner.get_timestamp()
  123    140   
    }
         141  +
    /* FluentBuilderGenerator.kt:282 */
  124    142   
}

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_header_date_time.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 `MalformedTimestampHeaderDateTime`.
           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 MalformedTimestampHeaderDateTime;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl MalformedTimestampHeaderDateTime {
    7         -
    /// Creates a new `MalformedTimestampHeaderDateTime`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `MalformedTimestampHeaderDateTime`
          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::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -63,72 +338,409 @@
   83     92   
                runtime_plugins = runtime_plugins.with_operation_plugin(plugin);
   84     93   
            }
   85     94   
            runtime_plugins = runtime_plugins.with_operation_plugin(crate::config::ConfigOverrideRuntimePlugin::new(
   86     95   
                config_override,
   87     96   
                client_config.config.clone(),
   88     97   
                &client_config.runtime_components,
   89     98   
            ));
   90     99   
        }
   91    100   
        runtime_plugins
   92    101   
    }
         102  +
    /* OperationGenerator.kt:85 */
   93    103   
}
         104  +
/* OperationRuntimePluginGenerator.kt:55 */
   94    105   
impl ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugin for MalformedTimestampHeaderDateTime {
   95    106   
    fn config(&self) -> ::std::option::Option<::aws_smithy_types::config_bag::FrozenLayer> {
   96    107   
        let mut cfg = ::aws_smithy_types::config_bag::Layer::new("MalformedTimestampHeaderDateTime");
   97    108   
   98    109   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   99    110   
            MalformedTimestampHeaderDateTimeRequestSerializer,
  100    111   
        ));
  101    112   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  102    113   
            MalformedTimestampHeaderDateTimeResponseDeserializer,
  103    114   
        ));
  104    115   
  105    116   
        cfg.store_put(::aws_smithy_runtime_api::client::auth::AuthSchemeOptionResolverParams::new(
  106    117   
            ::aws_smithy_runtime_api::client::auth::static_resolver::StaticAuthSchemeOptionResolverParams::new(),
  107    118   
        ));
  108    119   
  109    120   
        cfg.store_put(::aws_smithy_runtime_api::client::orchestrator::Metadata::new(
  110    121   
            "MalformedTimestampHeaderDateTime",
  111    122   
            "Rest Json Protocol",
  112    123   
        ));
  113    124   
  114    125   
        ::std::option::Option::Some(cfg.freeze())
  115    126   
    }
  116    127   
  117    128   
    fn runtime_components(
  118    129   
        &self,
  119    130   
        _: &::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder,
  120    131   
    ) -> ::std::borrow::Cow<'_, ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder> {
  121    132   
        #[allow(unused_mut)]
  122    133   
        let mut rcb = ::aws_smithy_runtime_api::client::runtime_components::RuntimeComponentsBuilder::new("MalformedTimestampHeaderDateTime")
  123    134   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  124    135   
            .with_interceptor(MalformedTimestampHeaderDateTimeEndpointParamsInterceptor)
  125    136   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  126    137   
                crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeError,
  127    138   
            >::new())
  128    139   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  129    140   
                crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeError,
  130    141   
            >::new());
  131    142   
  132    143   
        ::std::borrow::Cow::Owned(rcb)
  133    144   
    }
  134    145   
}
  135    146   
         147  +
/* ResponseDeserializerGenerator.kt:64 */
  136    148   
#[derive(Debug)]
  137    149   
struct MalformedTimestampHeaderDateTimeResponseDeserializer;
  138    150   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for MalformedTimestampHeaderDateTimeResponseDeserializer {
  139    151   
    fn deserialize_nonstreaming(
  140    152   
        &self,
  141    153   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
  142    154   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  143    155   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  144    156   
        let headers = response.headers();
  145    157   
        let body = response.body().bytes().expect("body loaded");
  146    158   
        #[allow(unused_mut)]
  147    159   
        let mut force_error = false;
  148    160   
  149    161   
        let parse_result = if !success && status != 200 || force_error {
  150    162   
            crate::protocol_serde::shape_malformed_timestamp_header_date_time::de_malformed_timestamp_header_date_time_http_error(
  151    163   
                status, headers, body,
  152    164   
            )
  153    165   
        } else {
  154    166   
            crate::protocol_serde::shape_malformed_timestamp_header_date_time::de_malformed_timestamp_header_date_time_http_response(
  155    167   
                status, headers, body,
  156    168   
            )
  157    169   
        };
  158    170   
        crate::protocol_serde::type_erase_result(parse_result)
  159    171   
    }
  160    172   
}
         173  +
/* RequestSerializerGenerator.kt:67 */
  161    174   
#[derive(Debug)]
  162    175   
struct MalformedTimestampHeaderDateTimeRequestSerializer;
  163    176   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for MalformedTimestampHeaderDateTimeRequestSerializer {
  164    177   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  165    178   
    fn serialize_input(
  166    179   
        &self,
  167    180   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  168    181   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  169    182   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  170    183   
        let input = input
  171    184   
            .downcast::<crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput>()
  172    185   
            .expect("correct type");
  173    186   
        let _header_serialization_settings = _cfg
  174    187   
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  175    188   
            .cloned()
  176    189   
            .unwrap_or_default();
  177    190   
        let mut request_builder = {
  178    191   
            fn uri_base(
  179    192   
                _input: &crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput,
  180    193   
                output: &mut ::std::string::String,
  181    194   
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  182    195   
                use ::std::fmt::Write as _;
  183    196   
                ::std::write!(output, "/MalformedTimestampHeaderDateTime").expect("formatting should succeed");
  184    197   
                ::std::result::Result::Ok(())
  185    198   
            }
  186    199   
            #[allow(clippy::unnecessary_wraps)]
  187    200   
            fn update_http_builder(
  188    201   
                input: &crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput,
  189    202   
                builder: ::http::request::Builder,
  190    203   
            ) -> ::std::result::Result<::http::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  191    204   
                let mut uri = ::std::string::String::new();
  192    205   
                uri_base(input, &mut uri)?;
  193    206   
                let builder = crate::protocol_serde::shape_malformed_timestamp_header_date_time::ser_malformed_timestamp_header_date_time_headers(
  194    207   
                    input, builder,
  195    208   
                )?;
  196    209   
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  197    210   
            }
  198    211   
            let mut builder = update_http_builder(&input, ::http::request::Builder::new())?;
  199    212   
            builder
  200    213   
        };
  201    214   
        let body = ::aws_smithy_types::body::SdkBody::from("");
  202    215   
  203    216   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  204    217   
    }
  205    218   
}
         219  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  206    220   
#[derive(Debug)]
  207    221   
struct MalformedTimestampHeaderDateTimeEndpointParamsInterceptor;
  208    222   
  209    223   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for MalformedTimestampHeaderDateTimeEndpointParamsInterceptor {
  210    224   
    fn name(&self) -> &'static str {
  211    225   
        "MalformedTimestampHeaderDateTimeEndpointParamsInterceptor"
  212    226   
    }
  213    227   
  214    228   
    fn read_before_execution(
  215    229   
        &self,
  216    230   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  217    231   
            '_,
  218    232   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  219    233   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  220    234   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  221    235   
        >,
  222    236   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  223    237   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  224    238   
        let _input = context
  225    239   
            .input()
  226    240   
            .downcast_ref::<MalformedTimestampHeaderDateTimeInput>()
  227    241   
            .ok_or("failed to downcast to MalformedTimestampHeaderDateTimeInput")?;
  228    242   
  229    243   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  230    244   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  231    245   
        })?;
  232    246   
        cfg.interceptor_state()
  233    247   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  234    248   
        ::std::result::Result::Ok(())
  235    249   
    }
  236    250   
}
  237    251   
  238    252   
// The get_* functions below are generated from JMESPath expressions in the
  239    253   
// operationContextParams trait. They target the operation's input shape.
  240    254   
         255  +
/* OperationErrorGenerator.kt:79 */
  241    256   
/// Error type for the `MalformedTimestampHeaderDateTimeError` operation.
         257  +
/* RustType.kt:516 */
  242    258   
#[non_exhaustive]
         259  +
/* RustType.kt:516 */
  243    260   
#[derive(::std::fmt::Debug)]
  244         -
pub enum MalformedTimestampHeaderDateTimeError {
         261  +
pub /* OperationErrorGenerator.kt:81 */ enum MalformedTimestampHeaderDateTimeError {
         262  +
    /* OperationErrorGenerator.kt:88 */
  245    263   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  246    264   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  247    265   
    variable wildcard pattern and check `.code()`:
  248    266   
     \
  249    267   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  250    268   
     \
  251    269   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-MalformedTimestampHeaderDateTimeError) for what information is available for the error.")]
  252    270   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         271  +
    /* OperationErrorGenerator.kt:81 */
  253    272   
}
         273  +
/* OperationErrorGenerator.kt:218 */
  254    274   
impl MalformedTimestampHeaderDateTimeError {
         275  +
    /* OperationErrorGenerator.kt:219 */
  255    276   
    /// Creates the `MalformedTimestampHeaderDateTimeError::Unhandled` variant from any error type.
  256    277   
    pub fn unhandled(
  257    278   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  258    279   
    ) -> Self {
  259    280   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  260    281   
            source: err.into(),
  261    282   
            meta: ::std::default::Default::default(),
  262    283   
        })
  263    284   
    }
  264    285   
  265    286   
    /// Creates the `MalformedTimestampHeaderDateTimeError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  266    287   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  267    288   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  268    289   
            source: err.clone().into(),
  269    290   
            meta: err,
  270    291   
        })
  271    292   
    }
  272         -
    ///
         293  +
    /// /* OperationErrorGenerator.kt:236 */
  273    294   
    /// Returns error metadata, which includes the error code, message,
  274    295   
    /// request ID, and potentially additional information.
  275    296   
    ///
         297  +
    /* OperationErrorGenerator.kt:242 */
  276    298   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         299  +
        /* OperationErrorGenerator.kt:243 */
  277    300   
        match self {
  278         -
            Self::Unhandled(e) => &e.meta,
         301  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         302  +
            /* OperationErrorGenerator.kt:243 */
  279    303   
        }
         304  +
        /* OperationErrorGenerator.kt:242 */
  280    305   
    }
         306  +
    /* OperationErrorGenerator.kt:218 */
  281    307   
}
         308  +
/* OperationErrorGenerator.kt:269 */
  282    309   
impl ::std::error::Error for MalformedTimestampHeaderDateTimeError {
         310  +
    /* OperationErrorGenerator.kt:270 */
  283    311   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         312  +
        /* OperationErrorGenerator.kt:318 */
  284    313   
        match self {
  285         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         314  +
            /* OperationErrorGenerator.kt:326 */
         315  +
            Self::Unhandled(_inner) => {
         316  +
                /* OperationErrorGenerator.kt:279 */
         317  +
                ::std::option::Option::Some(&*_inner.source)
         318  +
                /* OperationErrorGenerator.kt:326 */
         319  +
            } /* OperationErrorGenerator.kt:318 */
  286    320   
        }
         321  +
        /* OperationErrorGenerator.kt:270 */
  287    322   
    }
         323  +
    /* OperationErrorGenerator.kt:269 */
  288    324   
}
         325  +
/* OperationErrorGenerator.kt:133 */
  289    326   
impl ::std::fmt::Display for MalformedTimestampHeaderDateTimeError {
         327  +
    /* OperationErrorGenerator.kt:134 */
  290    328   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         329  +
        /* OperationErrorGenerator.kt:318 */
  291    330   
        match self {
         331  +
            /* OperationErrorGenerator.kt:326 */
  292    332   
            Self::Unhandled(_inner) => {
         333  +
                /* OperationErrorGenerator.kt:139 */
  293    334   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  294    335   
                    write!(f, "unhandled error ({code})")
  295    336   
                } else {
  296    337   
                    f.write_str("unhandled error")
  297    338   
                }
  298         -
            }
         339  +
                /* OperationErrorGenerator.kt:326 */
         340  +
            } /* OperationErrorGenerator.kt:318 */
  299    341   
        }
         342  +
        /* OperationErrorGenerator.kt:134 */
  300    343   
    }
         344  +
    /* OperationErrorGenerator.kt:133 */
  301    345   
}
         346  +
/* OperationErrorGenerator.kt:182 */
  302    347   
impl ::aws_smithy_types::retry::ProvideErrorKind for MalformedTimestampHeaderDateTimeError {
         348  +
    /* OperationErrorGenerator.kt:186 */
  303    349   
    fn code(&self) -> ::std::option::Option<&str> {
         350  +
        /* OperationErrorGenerator.kt:187 */
  304    351   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         352  +
        /* OperationErrorGenerator.kt:186 */
  305    353   
    }
         354  +
    /* OperationErrorGenerator.kt:190 */
  306    355   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         356  +
        /* OperationErrorGenerator.kt:197 */
  307    357   
        ::std::option::Option::None
         358  +
        /* OperationErrorGenerator.kt:190 */
  308    359   
    }
         360  +
    /* OperationErrorGenerator.kt:182 */
  309    361   
}
         362  +
/* OperationErrorGenerator.kt:163 */
  310    363   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for MalformedTimestampHeaderDateTimeError {
         364  +
    /* OperationErrorGenerator.kt:164 */
  311    365   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         366  +
        /* OperationErrorGenerator.kt:318 */
  312    367   
        match self {
  313         -
            Self::Unhandled(_inner) => &_inner.meta,
         368  +
            /* OperationErrorGenerator.kt:326 */
         369  +
            Self::Unhandled(_inner) => {
         370  +
                /* OperationErrorGenerator.kt:168 */
         371  +
                &_inner.meta
         372  +
                /* OperationErrorGenerator.kt:326 */
         373  +
            } /* OperationErrorGenerator.kt:318 */
  314    374   
        }
         375  +
        /* OperationErrorGenerator.kt:164 */
  315    376   
    }
         377  +
    /* OperationErrorGenerator.kt:163 */
  316    378   
}
         379  +
/* OperationErrorGenerator.kt:109 */
  317    380   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for MalformedTimestampHeaderDateTimeError {
         381  +
    /* OperationErrorGenerator.kt:110 */
  318    382   
    fn create_unhandled_error(
  319    383   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  320    384   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  321    385   
    ) -> Self {
         386  +
        /* OperationErrorGenerator.kt:121 */
  322    387   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  323    388   
            source,
  324    389   
            meta: meta.unwrap_or_default(),
  325    390   
        })
         391  +
        /* OperationErrorGenerator.kt:110 */
  326    392   
    }
         393  +
    /* OperationErrorGenerator.kt:109 */
  327    394   
}
  328    395   
         396  +
/* CodegenDelegator.kt:255 */
  329    397   
pub use crate::operation::malformed_timestamp_header_date_time::_malformed_timestamp_header_date_time_output::MalformedTimestampHeaderDateTimeOutput;
  330    398   
         399  +
/* CodegenDelegator.kt:255 */
  331    400   
pub use crate::operation::malformed_timestamp_header_date_time::_malformed_timestamp_header_date_time_input::MalformedTimestampHeaderDateTimeInput;
  332    401   
         402  +
/* RustModule.kt:172 */
  333    403   
mod _malformed_timestamp_header_date_time_input;
  334    404   
         405  +
/* RustModule.kt:172 */
  335    406   
mod _malformed_timestamp_header_date_time_output;
  336    407   
  337         -
/// Builders
         408  +
/// /* CodegenDelegator.kt:51 */Builders
  338    409   
pub mod builders;

tmp-codegen-diff/codegen-client-test/rest_json/rust-client-codegen/src/operation/malformed_timestamp_header_date_time/_malformed_timestamp_header_date_time_input.rs

@@ -1,1 +55,97 @@
    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 MalformedTimestampHeaderDateTimeInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct MalformedTimestampHeaderDateTimeInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          12  +
    /* StructureGenerator.kt:201 */
    8     13   
}
          14  +
/* StructureGenerator.kt:135 */
    9     15   
impl MalformedTimestampHeaderDateTimeInput {
          16  +
    /* StructureGenerator.kt:231 */
   10     17   
    #[allow(missing_docs)] // documentation missing in model
          18  +
                           /* StructureGenerator.kt:166 */
   11     19   
    pub fn timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
          20  +
        /* StructureGenerator.kt:170 */
   12     21   
        self.timestamp.as_ref()
          22  +
        /* StructureGenerator.kt:166 */
   13     23   
    }
          24  +
    /* StructureGenerator.kt:135 */
   14     25   
}
          26  +
/* ClientCodegenVisitor.kt:237 */
   15     27   
impl MalformedTimestampHeaderDateTimeInput {
   16         -
    /// Creates a new builder-style object to manufacture [`MalformedTimestampHeaderDateTimeInput`](crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput).
          28  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`MalformedTimestampHeaderDateTimeInput`](crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput).
          29  +
    /* BuilderGenerator.kt:175 */
   17     30   
    pub fn builder() -> crate::operation::malformed_timestamp_header_date_time::builders::MalformedTimestampHeaderDateTimeInputBuilder {
          31  +
        /* BuilderGenerator.kt:176 */
   18     32   
        crate::operation::malformed_timestamp_header_date_time::builders::MalformedTimestampHeaderDateTimeInputBuilder::default()
          33  +
        /* BuilderGenerator.kt:175 */
   19     34   
    }
          35  +
    /* ClientCodegenVisitor.kt:237 */
   20     36   
}
   21     37   
   22         -
/// A builder for [`MalformedTimestampHeaderDateTimeInput`](crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput).
          38  +
/// /* BuilderGenerator.kt:342 */A builder for [`MalformedTimestampHeaderDateTimeInput`](crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput).
          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 MalformedTimestampHeaderDateTimeInputBuilder {
   26         -
    pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          45  +
    /* BuilderGenerator.kt:275 */ pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
          46  +
    /* BuilderGenerator.kt:345 */
   27     47   
}
          48  +
/* BuilderGenerator.kt:355 */
   28     49   
impl MalformedTimestampHeaderDateTimeInputBuilder {
          50  +
    /* BuilderGenerator.kt:286 */
   29     51   
    #[allow(missing_docs)] // documentation missing in model
   30         -
    /// This field is required.
          52  +
    /// /* BuilderGenerator.kt:288 */This field is required.
          53  +
    /* BuilderGenerator.kt:291 */
   31     54   
    pub fn timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
          55  +
        /* BuilderGenerator.kt:292 */
   32     56   
        self.timestamp = ::std::option::Option::Some(input);
          57  +
        /* BuilderGenerator.kt:293 */
   33     58   
        self
          59  +
        /* BuilderGenerator.kt:291 */
   34     60   
    }
          61  +
    /* BuilderGenerator.kt:312 */
   35     62   
    #[allow(missing_docs)] // documentation missing in model
          63  +
                           /* BuilderGenerator.kt:314 */
   36     64   
    pub fn set_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
          65  +
        /* BuilderGenerator.kt:315 */
   37     66   
        self.timestamp = input;
   38     67   
        self
          68  +
        /* BuilderGenerator.kt:314 */
   39     69   
    }
          70  +
    /* BuilderGenerator.kt:334 */
   40     71   
    #[allow(missing_docs)] // documentation missing in model
          72  +
                           /* BuilderGenerator.kt:336 */
   41     73   
    pub fn get_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
          74  +
        /* BuilderGenerator.kt:337 */
   42     75   
        &self.timestamp
          76  +
        /* BuilderGenerator.kt:336 */
   43     77   
    }
   44         -
    /// Consumes the builder and constructs a [`MalformedTimestampHeaderDateTimeInput`](crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput).
          78  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`MalformedTimestampHeaderDateTimeInput`](crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput).
          79  +
    /* BuilderGenerator.kt:253 */
   45     80   
    pub fn build(
   46     81   
        self,
   47     82   
    ) -> ::std::result::Result<
   48     83   
        crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput,
   49     84   
        ::aws_smithy_types::error::operation::BuildError,
   50     85   
    > {
          86  +
        /* BuilderGenerator.kt:254 */
   51     87   
        ::std::result::Result::Ok(
   52         -
            crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput { timestamp: self.timestamp },
          88  +
            /* BuilderGenerator.kt:477 */
          89  +
            crate::operation::malformed_timestamp_header_date_time::MalformedTimestampHeaderDateTimeInput {
          90  +
                /* BuilderGenerator.kt:481 */ timestamp: self.timestamp,
          91  +
                /* BuilderGenerator.kt:477 */
          92  +
            }, /* BuilderGenerator.kt:254 */
   53     93   
        )
          94  +
        /* BuilderGenerator.kt:253 */
   54     95   
    }
          96  +
    /* BuilderGenerator.kt:355 */
   55     97   
}