Client Test

Client Test

rev. dfb5149b65b7bcc09edd15b8e071ad43b5ac5943

Files changed:

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/operation/sparse_nulls_operation.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 `SparseNullsOperation`.
           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 SparseNullsOperation;
          10  +
/* OperationGenerator.kt:85 */
    6     11   
impl SparseNullsOperation {
    7         -
    /// Creates a new `SparseNullsOperation`
          12  +
    /// /* OperationGenerator.kt:86 */Creates a new `SparseNullsOperation`
          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::sparse_nulls_operation::SparseNullsOperationInput,
   14     23   
    ) -> ::std::result::Result<
   15     24   
        crate::operation::sparse_nulls_operation::SparseNullsOperationOutput,
   16     25   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     26   
            crate::operation::sparse_nulls_operation::SparseNullsOperationError,
   18     27   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     28   
        >,
   20     29   
    > {
@@ -63,72 +275,292 @@
   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 SparseNullsOperation {
   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("SparseNullsOperation");
   97    108   
   98    109   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedRequestSerializer::new(
   99    110   
            SparseNullsOperationRequestSerializer,
  100    111   
        ));
  101    112   
        cfg.store_put(::aws_smithy_runtime_api::client::ser_de::SharedResponseDeserializer::new(
  102    113   
            SparseNullsOperationResponseDeserializer,
  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   
            "SparseNullsOperation",
  111    122   
            "RpcV2Protocol",
  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("SparseNullsOperation")
  123    134   
            .with_interceptor(::aws_smithy_runtime::client::stalled_stream_protection::StalledStreamProtectionInterceptor::default())
  124    135   
            .with_interceptor(SparseNullsOperationEndpointParamsInterceptor)
  125    136   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::TransientErrorClassifier::<
  126    137   
                crate::operation::sparse_nulls_operation::SparseNullsOperationError,
  127    138   
            >::new())
  128    139   
            .with_retry_classifier(::aws_smithy_runtime::client::retries::classifiers::ModeledAsRetryableClassifier::<
  129    140   
                crate::operation::sparse_nulls_operation::SparseNullsOperationError,
  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 SparseNullsOperationResponseDeserializer;
  138    150   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for SparseNullsOperationResponseDeserializer {
  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_sparse_nulls_operation::de_sparse_nulls_operation_http_error(status, headers, body)
  151    163   
        } else {
  152    164   
            crate::protocol_serde::shape_sparse_nulls_operation::de_sparse_nulls_operation_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 SparseNullsOperationRequestSerializer;
  159    172   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for SparseNullsOperationRequestSerializer {
  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::sparse_nulls_operation::SparseNullsOperationInput>()
  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::sparse_nulls_operation::SparseNullsOperationInput,
  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, "/service/RpcV2Protocol/operation/SparseNullsOperation").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::sparse_nulls_operation::SparseNullsOperationInput,
  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/cbor");
  193    206   
            builder =
  194    207   
                _header_serialization_settings.set_default_header(builder, ::http::header::HeaderName::from_static("smithy-protocol"), "rpc-v2-cbor");
  195    208   
            builder =
  196    209   
                _header_serialization_settings.set_default_header(builder, ::http::header::HeaderName::from_static("accept"), "application/cbor");
  197    210   
            builder
  198    211   
        };
  199    212   
        let body = ::aws_smithy_types::body::SdkBody::from(crate::protocol_serde::shape_sparse_nulls_operation::ser_sparse_nulls_operation_input(
  200    213   
            &input,
  201    214   
        )?);
  202    215   
        if let Some(content_length) = body.content_length() {
  203    216   
            let content_length = content_length.to_string();
  204    217   
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http::header::CONTENT_LENGTH, &content_length);
  205    218   
        }
  206    219   
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
  207    220   
    }
  208    221   
}
         222  +
/* EndpointParamsInterceptorGenerator.kt:86 */
  209    223   
#[derive(Debug)]
  210    224   
struct SparseNullsOperationEndpointParamsInterceptor;
  211    225   
  212    226   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for SparseNullsOperationEndpointParamsInterceptor {
  213    227   
    fn name(&self) -> &'static str {
  214    228   
        "SparseNullsOperationEndpointParamsInterceptor"
  215    229   
    }
  216    230   
  217    231   
    fn read_before_execution(
  218    232   
        &self,
  219    233   
        context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
  220    234   
            '_,
  221    235   
            ::aws_smithy_runtime_api::client::interceptors::context::Input,
  222    236   
            ::aws_smithy_runtime_api::client::interceptors::context::Output,
  223    237   
            ::aws_smithy_runtime_api::client::interceptors::context::Error,
  224    238   
        >,
  225    239   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  226    240   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  227    241   
        let _input = context
  228    242   
            .input()
  229    243   
            .downcast_ref::<SparseNullsOperationInput>()
  230    244   
            .ok_or("failed to downcast to SparseNullsOperationInput")?;
  231    245   
  232    246   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  233    247   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  234    248   
        })?;
  235    249   
        cfg.interceptor_state()
  236    250   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
  237    251   
        ::std::result::Result::Ok(())
  238    252   
    }
  239    253   
}
  240    254   
  241    255   
// The get_* functions below are generated from JMESPath expressions in the
  242    256   
// operationContextParams trait. They target the operation's input shape.
  243    257   
         258  +
/* RustType.kt:516 */
  244    259   
#[allow(unreachable_code, unused_variables)]
         260  +
/* RustType.kt:516 */
  245    261   
#[cfg(test)]
         262  +
/* ProtocolTestGenerator.kt:98 */
  246    263   
mod sparse_nulls_operation_test {
  247    264   
  248    265   
    /// Serializes null values in maps
  249    266   
    /// Test ID: RpcV2CborSparseMapsSerializeNullValues
  250    267   
    #[::tokio::test]
  251    268   
    #[::tracing_test::traced_test]
  252    269   
    async fn rpc_v2_cbor_sparse_maps_serialize_null_values_request() {
  253    270   
        let (http_client, request_receiver) = ::aws_smithy_http_client::test_util::capture_request(None);
  254    271   
        let config_builder = crate::config::Config::builder().with_test_defaults().endpoint_url("https://example.com");
  255    272   
@@ -399,416 +528,604 @@
  419    436   
            parsed.sparse_string_list,
  420    437   
            expected_output.sparse_string_list,
  421    438   
            "Unexpected value for `sparse_string_list`"
  422    439   
        );
  423    440   
        ::pretty_assertions::assert_eq!(
  424    441   
            parsed.sparse_string_map,
  425    442   
            expected_output.sparse_string_map,
  426    443   
            "Unexpected value for `sparse_string_map`"
  427    444   
        );
  428    445   
    }
         446  +
         447  +
    /* ProtocolTestGenerator.kt:98 */
  429    448   
}
  430    449   
         450  +
/* OperationErrorGenerator.kt:79 */
  431    451   
/// Error type for the `SparseNullsOperationError` operation.
         452  +
/* RustType.kt:516 */
  432    453   
#[non_exhaustive]
         454  +
/* RustType.kt:516 */
  433    455   
#[derive(::std::fmt::Debug)]
  434         -
pub enum SparseNullsOperationError {
         456  +
pub /* OperationErrorGenerator.kt:81 */ enum SparseNullsOperationError {
         457  +
    /* OperationErrorGenerator.kt:88 */
  435    458   
    /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
  436    459   
    #[deprecated(note = "Matching `Unhandled` directly is not forwards compatible. Instead, match using a \
  437    460   
    variable wildcard pattern and check `.code()`:
  438    461   
     \
  439    462   
    &nbsp;&nbsp;&nbsp;`err if err.code() == Some(\"SpecificExceptionCode\") => { /* handle the error */ }`
  440    463   
     \
  441    464   
    See [`ProvideErrorMetadata`](#impl-ProvideErrorMetadata-for-SparseNullsOperationError) for what information is available for the error.")]
  442    465   
    Unhandled(crate::error::sealed_unhandled::Unhandled),
         466  +
    /* OperationErrorGenerator.kt:81 */
  443    467   
}
         468  +
/* OperationErrorGenerator.kt:218 */
  444    469   
impl SparseNullsOperationError {
         470  +
    /* OperationErrorGenerator.kt:219 */
  445    471   
    /// Creates the `SparseNullsOperationError::Unhandled` variant from any error type.
  446    472   
    pub fn unhandled(
  447    473   
        err: impl ::std::convert::Into<::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>>,
  448    474   
    ) -> Self {
  449    475   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  450    476   
            source: err.into(),
  451    477   
            meta: ::std::default::Default::default(),
  452    478   
        })
  453    479   
    }
  454    480   
  455    481   
    /// Creates the `SparseNullsOperationError::Unhandled` variant from an [`ErrorMetadata`](::aws_smithy_types::error::ErrorMetadata).
  456    482   
    pub fn generic(err: ::aws_smithy_types::error::ErrorMetadata) -> Self {
  457    483   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  458    484   
            source: err.clone().into(),
  459    485   
            meta: err,
  460    486   
        })
  461    487   
    }
  462         -
    ///
         488  +
    /// /* OperationErrorGenerator.kt:236 */
  463    489   
    /// Returns error metadata, which includes the error code, message,
  464    490   
    /// request ID, and potentially additional information.
  465    491   
    ///
         492  +
    /* OperationErrorGenerator.kt:242 */
  466    493   
    pub fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         494  +
        /* OperationErrorGenerator.kt:243 */
  467    495   
        match self {
  468         -
            Self::Unhandled(e) => &e.meta,
         496  +
            /* OperationErrorGenerator.kt:251 */ Self::Unhandled(e) => &e.meta,
         497  +
            /* OperationErrorGenerator.kt:243 */
  469    498   
        }
         499  +
        /* OperationErrorGenerator.kt:242 */
  470    500   
    }
         501  +
    /* OperationErrorGenerator.kt:218 */
  471    502   
}
         503  +
/* OperationErrorGenerator.kt:269 */
  472    504   
impl ::std::error::Error for SparseNullsOperationError {
         505  +
    /* OperationErrorGenerator.kt:270 */
  473    506   
    fn source(&self) -> ::std::option::Option<&(dyn ::std::error::Error + 'static)> {
         507  +
        /* OperationErrorGenerator.kt:318 */
  474    508   
        match self {
  475         -
            Self::Unhandled(_inner) => ::std::option::Option::Some(&*_inner.source),
         509  +
            /* OperationErrorGenerator.kt:326 */
         510  +
            Self::Unhandled(_inner) => {
         511  +
                /* OperationErrorGenerator.kt:279 */
         512  +
                ::std::option::Option::Some(&*_inner.source)
         513  +
                /* OperationErrorGenerator.kt:326 */
         514  +
            } /* OperationErrorGenerator.kt:318 */
  476    515   
        }
         516  +
        /* OperationErrorGenerator.kt:270 */
  477    517   
    }
         518  +
    /* OperationErrorGenerator.kt:269 */
  478    519   
}
         520  +
/* OperationErrorGenerator.kt:133 */
  479    521   
impl ::std::fmt::Display for SparseNullsOperationError {
         522  +
    /* OperationErrorGenerator.kt:134 */
  480    523   
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
         524  +
        /* OperationErrorGenerator.kt:318 */
  481    525   
        match self {
         526  +
            /* OperationErrorGenerator.kt:326 */
  482    527   
            Self::Unhandled(_inner) => {
         528  +
                /* OperationErrorGenerator.kt:139 */
  483    529   
                if let ::std::option::Option::Some(code) = ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self) {
  484    530   
                    write!(f, "unhandled error ({code})")
  485    531   
                } else {
  486    532   
                    f.write_str("unhandled error")
  487    533   
                }
  488         -
            }
         534  +
                /* OperationErrorGenerator.kt:326 */
         535  +
            } /* OperationErrorGenerator.kt:318 */
  489    536   
        }
         537  +
        /* OperationErrorGenerator.kt:134 */
  490    538   
    }
         539  +
    /* OperationErrorGenerator.kt:133 */
  491    540   
}
         541  +
/* OperationErrorGenerator.kt:182 */
  492    542   
impl ::aws_smithy_types::retry::ProvideErrorKind for SparseNullsOperationError {
         543  +
    /* OperationErrorGenerator.kt:186 */
  493    544   
    fn code(&self) -> ::std::option::Option<&str> {
         545  +
        /* OperationErrorGenerator.kt:187 */
  494    546   
        ::aws_smithy_types::error::metadata::ProvideErrorMetadata::code(self)
         547  +
        /* OperationErrorGenerator.kt:186 */
  495    548   
    }
         549  +
    /* OperationErrorGenerator.kt:190 */
  496    550   
    fn retryable_error_kind(&self) -> ::std::option::Option<::aws_smithy_types::retry::ErrorKind> {
         551  +
        /* OperationErrorGenerator.kt:197 */
  497    552   
        ::std::option::Option::None
         553  +
        /* OperationErrorGenerator.kt:190 */
  498    554   
    }
         555  +
    /* OperationErrorGenerator.kt:182 */
  499    556   
}
         557  +
/* OperationErrorGenerator.kt:163 */
  500    558   
impl ::aws_smithy_types::error::metadata::ProvideErrorMetadata for SparseNullsOperationError {
         559  +
    /* OperationErrorGenerator.kt:164 */
  501    560   
    fn meta(&self) -> &::aws_smithy_types::error::ErrorMetadata {
         561  +
        /* OperationErrorGenerator.kt:318 */
  502    562   
        match self {
  503         -
            Self::Unhandled(_inner) => &_inner.meta,
         563  +
            /* OperationErrorGenerator.kt:326 */
         564  +
            Self::Unhandled(_inner) => {
         565  +
                /* OperationErrorGenerator.kt:168 */
         566  +
                &_inner.meta
         567  +
                /* OperationErrorGenerator.kt:326 */
         568  +
            } /* OperationErrorGenerator.kt:318 */
  504    569   
        }
         570  +
        /* OperationErrorGenerator.kt:164 */
  505    571   
    }
         572  +
    /* OperationErrorGenerator.kt:163 */
  506    573   
}
         574  +
/* OperationErrorGenerator.kt:109 */
  507    575   
impl ::aws_smithy_runtime_api::client::result::CreateUnhandledError for SparseNullsOperationError {
         576  +
    /* OperationErrorGenerator.kt:110 */
  508    577   
    fn create_unhandled_error(
  509    578   
        source: ::std::boxed::Box<dyn ::std::error::Error + ::std::marker::Send + ::std::marker::Sync + 'static>,
  510    579   
        meta: ::std::option::Option<::aws_smithy_types::error::ErrorMetadata>,
  511    580   
    ) -> Self {
         581  +
        /* OperationErrorGenerator.kt:121 */
  512    582   
        Self::Unhandled(crate::error::sealed_unhandled::Unhandled {
  513    583   
            source,
  514    584   
            meta: meta.unwrap_or_default(),
  515    585   
        })
         586  +
        /* OperationErrorGenerator.kt:110 */
  516    587   
    }
         588  +
    /* OperationErrorGenerator.kt:109 */
  517    589   
}
  518    590   
         591  +
/* CodegenDelegator.kt:255 */
  519    592   
pub use crate::operation::sparse_nulls_operation::_sparse_nulls_operation_output::SparseNullsOperationOutput;
  520    593   
         594  +
/* CodegenDelegator.kt:255 */
  521    595   
pub use crate::operation::sparse_nulls_operation::_sparse_nulls_operation_input::SparseNullsOperationInput;
  522    596   
         597  +
/* RustModule.kt:172 */
  523    598   
mod _sparse_nulls_operation_input;
  524    599   
         600  +
/* RustModule.kt:172 */
  525    601   
mod _sparse_nulls_operation_output;
  526    602   
  527         -
/// Builders
         603  +
/// /* CodegenDelegator.kt:51 */Builders
  528    604   
pub mod builders;

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/operation/sparse_nulls_operation/_sparse_nulls_operation_input.rs

@@ -1,1 +94,160 @@
    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 SparseNullsOperationInput {
           8  +
pub /* StructureGenerator.kt:201 */ struct SparseNullsOperationInput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub sparse_string_list: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>,
          12  +
    /* StructureGenerator.kt:231 */
    8     13   
    #[allow(missing_docs)] // documentation missing in model
    9     14   
    pub sparse_string_map: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
          15  +
    /* StructureGenerator.kt:201 */
   10     16   
}
          17  +
/* StructureGenerator.kt:135 */
   11     18   
impl SparseNullsOperationInput {
          19  +
    /* StructureGenerator.kt:231 */
   12     20   
    #[allow(missing_docs)] // documentation missing in model
   13         -
    ///
   14         -
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.sparse_string_list.is_none()`.
          21  +
    /// /* StructureGenerator.kt:162 */
          22  +
    /// /* StructureGenerator.kt:163 */If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.sparse_string_list.is_none()`.
          23  +
    /* StructureGenerator.kt:166 */
   15     24   
    pub fn sparse_string_list(&self) -> &[::std::option::Option<::std::string::String>] {
   16         -
        self.sparse_string_list.as_deref().unwrap_or_default()
          25  +
        /* StructureGenerator.kt:169 */
          26  +
        self.sparse_string_list
          27  +
            .as_deref()
          28  +
            /* StructureGenerator.kt:175 */
          29  +
            .unwrap_or_default()
          30  +
        /* StructureGenerator.kt:166 */
   17     31   
    }
          32  +
    /* StructureGenerator.kt:231 */
   18     33   
    #[allow(missing_docs)] // documentation missing in model
          34  +
                           /* StructureGenerator.kt:166 */
   19     35   
    pub fn sparse_string_map(
   20     36   
        &self,
   21     37   
    ) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>> {
          38  +
        /* StructureGenerator.kt:170 */
   22     39   
        self.sparse_string_map.as_ref()
          40  +
        /* StructureGenerator.kt:166 */
   23     41   
    }
          42  +
    /* StructureGenerator.kt:135 */
   24     43   
}
          44  +
/* ClientCodegenVisitor.kt:237 */
   25     45   
impl SparseNullsOperationInput {
   26         -
    /// Creates a new builder-style object to manufacture [`SparseNullsOperationInput`](crate::operation::sparse_nulls_operation::SparseNullsOperationInput).
          46  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`SparseNullsOperationInput`](crate::operation::sparse_nulls_operation::SparseNullsOperationInput).
          47  +
    /* BuilderGenerator.kt:175 */
   27     48   
    pub fn builder() -> crate::operation::sparse_nulls_operation::builders::SparseNullsOperationInputBuilder {
          49  +
        /* BuilderGenerator.kt:176 */
   28     50   
        crate::operation::sparse_nulls_operation::builders::SparseNullsOperationInputBuilder::default()
          51  +
        /* BuilderGenerator.kt:175 */
   29     52   
    }
          53  +
    /* ClientCodegenVisitor.kt:237 */
   30     54   
}
   31     55   
   32         -
/// A builder for [`SparseNullsOperationInput`](crate::operation::sparse_nulls_operation::SparseNullsOperationInput).
          56  +
/// /* BuilderGenerator.kt:342 */A builder for [`SparseNullsOperationInput`](crate::operation::sparse_nulls_operation::SparseNullsOperationInput).
          57  +
/* RustType.kt:516 */
   33     58   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          59  +
/* RustType.kt:516 */
   34     60   
#[non_exhaustive]
          61  +
/* BuilderGenerator.kt:345 */
   35     62   
pub struct SparseNullsOperationInputBuilder {
          63  +
    /* BuilderGenerator.kt:275 */
   36     64   
    pub(crate) sparse_string_list: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>,
          65  +
    /* BuilderGenerator.kt:275 */
   37     66   
    pub(crate) sparse_string_map:
   38     67   
        ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
          68  +
    /* BuilderGenerator.kt:345 */
   39     69   
}
          70  +
/* BuilderGenerator.kt:355 */
   40     71   
impl SparseNullsOperationInputBuilder {
   41         -
    /// Appends an item to `sparse_string_list`.
          72  +
    /// /* BuilderGenerator.kt:410 */Appends an item to `sparse_string_list`.
          73  +
    /* BuilderGenerator.kt:411 */
   42     74   
    ///
   43         -
    /// To override the contents of this collection use [`set_sparse_string_list`](Self::set_sparse_string_list).
          75  +
    /// /* BuilderGenerator.kt:412 */To override the contents of this collection use [`set_sparse_string_list`](Self::set_sparse_string_list).
          76  +
    /* BuilderGenerator.kt:413 */
   44     77   
    ///
          78  +
    /* BuilderGenerator.kt:418 */
   45     79   
    pub fn sparse_string_list(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
          80  +
        /* BuilderGenerator.kt:419 */
   46     81   
        let mut v = self.sparse_string_list.unwrap_or_default();
   47     82   
        v.push(input);
   48     83   
        self.sparse_string_list = ::std::option::Option::Some(v);
   49     84   
        self
          85  +
        /* BuilderGenerator.kt:418 */
   50     86   
    }
          87  +
    /* BuilderGenerator.kt:312 */
   51     88   
    #[allow(missing_docs)] // documentation missing in model
          89  +
                           /* BuilderGenerator.kt:314 */
   52     90   
    pub fn set_sparse_string_list(mut self, input: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>) -> Self {
          91  +
        /* BuilderGenerator.kt:315 */
   53     92   
        self.sparse_string_list = input;
   54     93   
        self
          94  +
        /* BuilderGenerator.kt:314 */
   55     95   
    }
          96  +
    /* BuilderGenerator.kt:334 */
   56     97   
    #[allow(missing_docs)] // documentation missing in model
          98  +
                           /* BuilderGenerator.kt:336 */
   57     99   
    pub fn get_sparse_string_list(&self) -> &::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>> {
         100  +
        /* BuilderGenerator.kt:337 */
   58    101   
        &self.sparse_string_list
         102  +
        /* BuilderGenerator.kt:336 */
   59    103   
    }
   60         -
    /// Adds a key-value pair to `sparse_string_map`.
         104  +
    /// /* BuilderGenerator.kt:436 */Adds a key-value pair to `sparse_string_map`.
         105  +
    /* BuilderGenerator.kt:437 */
   61    106   
    ///
   62         -
    /// To override the contents of this collection use [`set_sparse_string_map`](Self::set_sparse_string_map).
         107  +
    /// /* BuilderGenerator.kt:438 */To override the contents of this collection use [`set_sparse_string_map`](Self::set_sparse_string_map).
         108  +
    /* BuilderGenerator.kt:439 */
   63    109   
    ///
         110  +
    /* BuilderGenerator.kt:445 */
   64    111   
    pub fn sparse_string_map(mut self, k: impl ::std::convert::Into<::std::string::String>, v: ::std::option::Option<::std::string::String>) -> Self {
         112  +
        /* BuilderGenerator.kt:448 */
   65    113   
        let mut hash_map = self.sparse_string_map.unwrap_or_default();
   66    114   
        hash_map.insert(k.into(), v);
   67    115   
        self.sparse_string_map = ::std::option::Option::Some(hash_map);
   68    116   
        self
         117  +
        /* BuilderGenerator.kt:445 */
   69    118   
    }
         119  +
    /* BuilderGenerator.kt:312 */
   70    120   
    #[allow(missing_docs)] // documentation missing in model
         121  +
                           /* BuilderGenerator.kt:314 */
   71    122   
    pub fn set_sparse_string_map(
   72    123   
        mut self,
   73    124   
        input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
   74    125   
    ) -> Self {
         126  +
        /* BuilderGenerator.kt:315 */
   75    127   
        self.sparse_string_map = input;
   76    128   
        self
         129  +
        /* BuilderGenerator.kt:314 */
   77    130   
    }
         131  +
    /* BuilderGenerator.kt:334 */
   78    132   
    #[allow(missing_docs)] // documentation missing in model
         133  +
                           /* BuilderGenerator.kt:336 */
   79    134   
    pub fn get_sparse_string_map(
   80    135   
        &self,
   81    136   
    ) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>> {
         137  +
        /* BuilderGenerator.kt:337 */
   82    138   
        &self.sparse_string_map
         139  +
        /* BuilderGenerator.kt:336 */
   83    140   
    }
   84         -
    /// Consumes the builder and constructs a [`SparseNullsOperationInput`](crate::operation::sparse_nulls_operation::SparseNullsOperationInput).
         141  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`SparseNullsOperationInput`](crate::operation::sparse_nulls_operation::SparseNullsOperationInput).
         142  +
    /* BuilderGenerator.kt:253 */
   85    143   
    pub fn build(
   86    144   
        self,
   87    145   
    ) -> ::std::result::Result<crate::operation::sparse_nulls_operation::SparseNullsOperationInput, ::aws_smithy_types::error::operation::BuildError>
   88    146   
    {
   89         -
        ::std::result::Result::Ok(crate::operation::sparse_nulls_operation::SparseNullsOperationInput {
   90         -
            sparse_string_list: self.sparse_string_list,
   91         -
            sparse_string_map: self.sparse_string_map,
   92         -
        })
         147  +
        /* BuilderGenerator.kt:254 */
         148  +
        ::std::result::Result::Ok(
         149  +
            /* BuilderGenerator.kt:477 */
         150  +
            crate::operation::sparse_nulls_operation::SparseNullsOperationInput {
         151  +
                /* BuilderGenerator.kt:481 */ sparse_string_list: self.sparse_string_list,
         152  +
                /* BuilderGenerator.kt:481 */
         153  +
                sparse_string_map: self.sparse_string_map,
         154  +
                /* BuilderGenerator.kt:477 */
         155  +
            }, /* BuilderGenerator.kt:254 */
         156  +
        )
         157  +
        /* BuilderGenerator.kt:253 */
   93    158   
    }
         159  +
    /* BuilderGenerator.kt:355 */
   94    160   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/operation/sparse_nulls_operation/_sparse_nulls_operation_output.rs

@@ -1,1 +91,154 @@
    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 SparseNullsOperationOutput {
           8  +
pub /* StructureGenerator.kt:201 */ struct SparseNullsOperationOutput {
           9  +
    /* StructureGenerator.kt:231 */
    6     10   
    #[allow(missing_docs)] // documentation missing in model
    7     11   
    pub sparse_string_list: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>,
          12  +
    /* StructureGenerator.kt:231 */
    8     13   
    #[allow(missing_docs)] // documentation missing in model
    9     14   
    pub sparse_string_map: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
          15  +
    /* StructureGenerator.kt:201 */
   10     16   
}
          17  +
/* StructureGenerator.kt:135 */
   11     18   
impl SparseNullsOperationOutput {
          19  +
    /* StructureGenerator.kt:231 */
   12     20   
    #[allow(missing_docs)] // documentation missing in model
   13         -
    ///
   14         -
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.sparse_string_list.is_none()`.
          21  +
    /// /* StructureGenerator.kt:162 */
          22  +
    /// /* StructureGenerator.kt:163 */If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.sparse_string_list.is_none()`.
          23  +
    /* StructureGenerator.kt:166 */
   15     24   
    pub fn sparse_string_list(&self) -> &[::std::option::Option<::std::string::String>] {
   16         -
        self.sparse_string_list.as_deref().unwrap_or_default()
          25  +
        /* StructureGenerator.kt:169 */
          26  +
        self.sparse_string_list
          27  +
            .as_deref()
          28  +
            /* StructureGenerator.kt:175 */
          29  +
            .unwrap_or_default()
          30  +
        /* StructureGenerator.kt:166 */
   17     31   
    }
          32  +
    /* StructureGenerator.kt:231 */
   18     33   
    #[allow(missing_docs)] // documentation missing in model
          34  +
                           /* StructureGenerator.kt:166 */
   19     35   
    pub fn sparse_string_map(
   20     36   
        &self,
   21     37   
    ) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>> {
          38  +
        /* StructureGenerator.kt:170 */
   22     39   
        self.sparse_string_map.as_ref()
          40  +
        /* StructureGenerator.kt:166 */
   23     41   
    }
          42  +
    /* StructureGenerator.kt:135 */
   24     43   
}
          44  +
/* ClientCodegenVisitor.kt:237 */
   25     45   
impl SparseNullsOperationOutput {
   26         -
    /// Creates a new builder-style object to manufacture [`SparseNullsOperationOutput`](crate::operation::sparse_nulls_operation::SparseNullsOperationOutput).
          46  +
    /// /* BuilderGenerator.kt:173 */Creates a new builder-style object to manufacture [`SparseNullsOperationOutput`](crate::operation::sparse_nulls_operation::SparseNullsOperationOutput).
          47  +
    /* BuilderGenerator.kt:175 */
   27     48   
    pub fn builder() -> crate::operation::sparse_nulls_operation::builders::SparseNullsOperationOutputBuilder {
          49  +
        /* BuilderGenerator.kt:176 */
   28     50   
        crate::operation::sparse_nulls_operation::builders::SparseNullsOperationOutputBuilder::default()
          51  +
        /* BuilderGenerator.kt:175 */
   29     52   
    }
          53  +
    /* ClientCodegenVisitor.kt:237 */
   30     54   
}
   31     55   
   32         -
/// A builder for [`SparseNullsOperationOutput`](crate::operation::sparse_nulls_operation::SparseNullsOperationOutput).
          56  +
/// /* BuilderGenerator.kt:342 */A builder for [`SparseNullsOperationOutput`](crate::operation::sparse_nulls_operation::SparseNullsOperationOutput).
          57  +
/* RustType.kt:516 */
   33     58   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
          59  +
/* RustType.kt:516 */
   34     60   
#[non_exhaustive]
          61  +
/* BuilderGenerator.kt:345 */
   35     62   
pub struct SparseNullsOperationOutputBuilder {
          63  +
    /* BuilderGenerator.kt:275 */
   36     64   
    pub(crate) sparse_string_list: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>,
          65  +
    /* BuilderGenerator.kt:275 */
   37     66   
    pub(crate) sparse_string_map:
   38     67   
        ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
          68  +
    /* BuilderGenerator.kt:345 */
   39     69   
}
          70  +
/* BuilderGenerator.kt:355 */
   40     71   
impl SparseNullsOperationOutputBuilder {
   41         -
    /// Appends an item to `sparse_string_list`.
          72  +
    /// /* BuilderGenerator.kt:410 */Appends an item to `sparse_string_list`.
          73  +
    /* BuilderGenerator.kt:411 */
   42     74   
    ///
   43         -
    /// To override the contents of this collection use [`set_sparse_string_list`](Self::set_sparse_string_list).
          75  +
    /// /* BuilderGenerator.kt:412 */To override the contents of this collection use [`set_sparse_string_list`](Self::set_sparse_string_list).
          76  +
    /* BuilderGenerator.kt:413 */
   44     77   
    ///
          78  +
    /* BuilderGenerator.kt:418 */
   45     79   
    pub fn sparse_string_list(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
          80  +
        /* BuilderGenerator.kt:419 */
   46     81   
        let mut v = self.sparse_string_list.unwrap_or_default();
   47     82   
        v.push(input);
   48     83   
        self.sparse_string_list = ::std::option::Option::Some(v);
   49     84   
        self
          85  +
        /* BuilderGenerator.kt:418 */
   50     86   
    }
          87  +
    /* BuilderGenerator.kt:312 */
   51     88   
    #[allow(missing_docs)] // documentation missing in model
          89  +
                           /* BuilderGenerator.kt:314 */
   52     90   
    pub fn set_sparse_string_list(mut self, input: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>) -> Self {
          91  +
        /* BuilderGenerator.kt:315 */
   53     92   
        self.sparse_string_list = input;
   54     93   
        self
          94  +
        /* BuilderGenerator.kt:314 */
   55     95   
    }
          96  +
    /* BuilderGenerator.kt:334 */
   56     97   
    #[allow(missing_docs)] // documentation missing in model
          98  +
                           /* BuilderGenerator.kt:336 */
   57     99   
    pub fn get_sparse_string_list(&self) -> &::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>> {
         100  +
        /* BuilderGenerator.kt:337 */
   58    101   
        &self.sparse_string_list
         102  +
        /* BuilderGenerator.kt:336 */
   59    103   
    }
   60         -
    /// Adds a key-value pair to `sparse_string_map`.
         104  +
    /// /* BuilderGenerator.kt:436 */Adds a key-value pair to `sparse_string_map`.
         105  +
    /* BuilderGenerator.kt:437 */
   61    106   
    ///
   62         -
    /// To override the contents of this collection use [`set_sparse_string_map`](Self::set_sparse_string_map).
         107  +
    /// /* BuilderGenerator.kt:438 */To override the contents of this collection use [`set_sparse_string_map`](Self::set_sparse_string_map).
         108  +
    /* BuilderGenerator.kt:439 */
   63    109   
    ///
         110  +
    /* BuilderGenerator.kt:445 */
   64    111   
    pub fn sparse_string_map(mut self, k: impl ::std::convert::Into<::std::string::String>, v: ::std::option::Option<::std::string::String>) -> Self {
         112  +
        /* BuilderGenerator.kt:448 */
   65    113   
        let mut hash_map = self.sparse_string_map.unwrap_or_default();
   66    114   
        hash_map.insert(k.into(), v);
   67    115   
        self.sparse_string_map = ::std::option::Option::Some(hash_map);
   68    116   
        self
         117  +
        /* BuilderGenerator.kt:445 */
   69    118   
    }
         119  +
    /* BuilderGenerator.kt:312 */
   70    120   
    #[allow(missing_docs)] // documentation missing in model
         121  +
                           /* BuilderGenerator.kt:314 */
   71    122   
    pub fn set_sparse_string_map(
   72    123   
        mut self,
   73    124   
        input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
   74    125   
    ) -> Self {
         126  +
        /* BuilderGenerator.kt:315 */
   75    127   
        self.sparse_string_map = input;
   76    128   
        self
         129  +
        /* BuilderGenerator.kt:314 */
   77    130   
    }
         131  +
    /* BuilderGenerator.kt:334 */
   78    132   
    #[allow(missing_docs)] // documentation missing in model
         133  +
                           /* BuilderGenerator.kt:336 */
   79    134   
    pub fn get_sparse_string_map(
   80    135   
        &self,
   81    136   
    ) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>> {
         137  +
        /* BuilderGenerator.kt:337 */
   82    138   
        &self.sparse_string_map
         139  +
        /* BuilderGenerator.kt:336 */
   83    140   
    }
   84         -
    /// Consumes the builder and constructs a [`SparseNullsOperationOutput`](crate::operation::sparse_nulls_operation::SparseNullsOperationOutput).
         141  +
    /// /* BuilderGenerator.kt:240 */Consumes the builder and constructs a [`SparseNullsOperationOutput`](crate::operation::sparse_nulls_operation::SparseNullsOperationOutput).
         142  +
    /* BuilderGenerator.kt:253 */
   85    143   
    pub fn build(self) -> crate::operation::sparse_nulls_operation::SparseNullsOperationOutput {
         144  +
        /* BuilderGenerator.kt:477 */
   86    145   
        crate::operation::sparse_nulls_operation::SparseNullsOperationOutput {
   87         -
            sparse_string_list: self.sparse_string_list,
         146  +
            /* BuilderGenerator.kt:481 */ sparse_string_list: self.sparse_string_list,
         147  +
            /* BuilderGenerator.kt:481 */
   88    148   
            sparse_string_map: self.sparse_string_map,
         149  +
            /* BuilderGenerator.kt:477 */
   89    150   
        }
         151  +
        /* BuilderGenerator.kt:253 */
   90    152   
    }
         153  +
    /* BuilderGenerator.kt:355 */
   91    154   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/operation/sparse_nulls_operation/builders.rs

@@ -1,1 +153,177 @@
    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::sparse_nulls_operation::_sparse_nulls_operation_output::SparseNullsOperationOutputBuilder;
    3      4   
           5  +
/* CodegenDelegator.kt:255 */
    4      6   
pub use crate::operation::sparse_nulls_operation::_sparse_nulls_operation_input::SparseNullsOperationInputBuilder;
    5      7   
           8  +
/* FluentBuilderGenerator.kt:408 */
    6      9   
impl crate::operation::sparse_nulls_operation::builders::SparseNullsOperationInputBuilder {
    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::sparse_nulls_operation::SparseNullsOperationOutput,
   13     16   
        ::aws_smithy_runtime_api::client::result::SdkError<
   14     17   
            crate::operation::sparse_nulls_operation::SparseNullsOperationError,
   15     18   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   16     19   
        >,
   17     20   
    > {
   18     21   
        let mut fluent_builder = client.sparse_nulls_operation();
   19     22   
        fluent_builder.inner = self;
   20     23   
        fluent_builder.send().await
   21     24   
    }
   22     25   
}
   23         -
/// Fluent builder constructing a request to `SparseNullsOperation`.
          26  +
/// /* FluentBuilderGenerator.kt:129 */Fluent builder constructing a request to `SparseNullsOperation`.
   24     27   
///
          28  +
/* RustType.kt:516 */
   25     29   
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
          30  +
/* FluentBuilderGenerator.kt:270 */
   26     31   
pub struct SparseNullsOperationFluentBuilder {
   27     32   
    handle: ::std::sync::Arc<crate::client::Handle>,
   28     33   
    inner: crate::operation::sparse_nulls_operation::builders::SparseNullsOperationInputBuilder,
   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::sparse_nulls_operation::SparseNullsOperationOutput,
   34     40   
        crate::operation::sparse_nulls_operation::SparseNullsOperationError,
   35     41   
    > for SparseNullsOperationFluentBuilder
   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::sparse_nulls_operation::SparseNullsOperationOutput,
   43     49   
            crate::operation::sparse_nulls_operation::SparseNullsOperationError,
   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 SparseNullsOperationFluentBuilder {
          57  +
    /* FluentBuilderGenerator.kt:288 */
   50     58   
    /// Creates a new `SparseNullsOperationFluentBuilder`.
   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 SparseNullsOperation as a reference.
   59     68   
    pub fn as_input(&self) -> &crate::operation::sparse_nulls_operation::builders::SparseNullsOperationInputBuilder {
   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::sparse_nulls_operation::SparseNullsOperationOutput,
   74     84   
        ::aws_smithy_runtime_api::client::result::SdkError<
   75     85   
            crate::operation::sparse_nulls_operation::SparseNullsOperationError,
   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::sparse_nulls_operation::SparseNullsOperation::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::sparse_nulls_operation::SparseNullsOperation::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::sparse_nulls_operation::SparseNullsOperationOutput,
   96    106   
        crate::operation::sparse_nulls_operation::SparseNullsOperationError,
   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   
    }
  110         -
    ///
         121  +
    /// /* FluentBuilderGenerator.kt:436 */
  111    122   
    /// Appends an item to `sparseStringList`.
  112    123   
    ///
  113    124   
    /// To override the contents of this collection use [`set_sparse_string_list`](Self::set_sparse_string_list).
  114    125   
    ///
         126  +
    /* FluentBuilderGenerator.kt:443 */
  115    127   
    #[allow(missing_docs)] // documentation missing in model
         128  +
                           /* FluentBuilderGenerator.kt:446 */
  116    129   
    pub fn sparse_string_list(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
  117    130   
        self.inner = self.inner.sparse_string_list(input);
  118    131   
        self
  119    132   
    }
         133  +
    /* FluentBuilderGenerator.kt:498 */
  120    134   
    #[allow(missing_docs)] // documentation missing in model
         135  +
                           /* FluentBuilderGenerator.kt:500 */
  121    136   
    pub fn set_sparse_string_list(mut self, input: ::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>>) -> Self {
  122    137   
        self.inner = self.inner.set_sparse_string_list(input);
  123    138   
        self
  124    139   
    }
         140  +
    /* FluentBuilderGenerator.kt:518 */
  125    141   
    #[allow(missing_docs)] // documentation missing in model
         142  +
                           /* FluentBuilderGenerator.kt:520 */
  126    143   
    pub fn get_sparse_string_list(&self) -> &::std::option::Option<::std::vec::Vec<::std::option::Option<::std::string::String>>> {
  127    144   
        self.inner.get_sparse_string_list()
  128    145   
    }
  129         -
    ///
         146  +
    /// /* FluentBuilderGenerator.kt:466 */
  130    147   
    /// Adds a key-value pair to `sparseStringMap`.
  131    148   
    ///
  132    149   
    /// To override the contents of this collection use [`set_sparse_string_map`](Self::set_sparse_string_map).
  133    150   
    ///
         151  +
    /* FluentBuilderGenerator.kt:473 */
  134    152   
    #[allow(missing_docs)] // documentation missing in model
         153  +
                           /* FluentBuilderGenerator.kt:475 */
  135    154   
    pub fn sparse_string_map(mut self, k: impl ::std::convert::Into<::std::string::String>, v: ::std::option::Option<::std::string::String>) -> Self {
  136    155   
        self.inner = self.inner.sparse_string_map(k.into(), v);
  137    156   
        self
  138    157   
    }
         158  +
    /* FluentBuilderGenerator.kt:498 */
  139    159   
    #[allow(missing_docs)] // documentation missing in model
         160  +
                           /* FluentBuilderGenerator.kt:500 */
  140    161   
    pub fn set_sparse_string_map(
  141    162   
        mut self,
  142    163   
        input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>>,
  143    164   
    ) -> Self {
  144    165   
        self.inner = self.inner.set_sparse_string_map(input);
  145    166   
        self
  146    167   
    }
         168  +
    /* FluentBuilderGenerator.kt:518 */
  147    169   
    #[allow(missing_docs)] // documentation missing in model
         170  +
                           /* FluentBuilderGenerator.kt:520 */
  148    171   
    pub fn get_sparse_string_map(
  149    172   
        &self,
  150    173   
    ) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::option::Option<::std::string::String>>> {
  151    174   
        self.inner.get_sparse_string_map()
  152    175   
    }
         176  +
    /* FluentBuilderGenerator.kt:282 */
  153    177   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/primitives.rs

@@ -1,1 +9,10 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* SmithyTypesPubUseExtra.kt:66 */
    2      3   
pub use ::aws_smithy_types::date_time::Format as DateTimeFormat;
    3      4   
pub use ::aws_smithy_types::Blob;
    4         -
pub use ::aws_smithy_types::DateTime;
           5  +
/* SmithyTypesPubUseExtra.kt:69 */ pub use ::aws_smithy_types::DateTime;
    5      6   
    6         -
/// Event stream related primitives such as `Message` or `Header`.
           7  +
/// /* ClientRustModule.kt:121 */Event stream related primitives such as `Message` or `Header`.
    7      8   
pub mod event_stream;
    8      9   
    9     10   
pub(crate) mod sealed_enum_unknown;

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/primitives/sealed_enum_unknown.rs

@@ -1,1 +21,29 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
    3         -
/// Opaque struct used as inner data for the `Unknown` variant defined in enums in
           2  +
/* ClientEnumGenerator.kt:189 */
           3  +
/// /* ClientEnumGenerator.kt:189 */Opaque struct used as inner data for the `Unknown` variant defined in enums in
    4      4   
/// the crate.
    5      5   
///
    6      6   
/// This is not intended to be used directly.
           7  +
/* RustType.kt:516 */
    7      8   
#[non_exhaustive]
           9  +
/* RustType.kt:516 */
    8     10   
#[derive(
    9     11   
    ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::Ord, ::std::cmp::PartialEq, ::std::cmp::PartialOrd, ::std::fmt::Debug, ::std::hash::Hash,
   10     12   
)]
   11         -
pub struct UnknownVariantValue(pub(crate) ::std::string::String);
          13  +
pub /* ClientEnumGenerator.kt:203 */ struct UnknownVariantValue(pub(crate) ::std::string::String);
          14  +
/* ClientEnumGenerator.kt:204 */
   12     15   
impl UnknownVariantValue {
          16  +
    /* ClientEnumGenerator.kt:206 */
   13     17   
    pub(crate) fn as_str(&self) -> &str {
          18  +
        /* ClientEnumGenerator.kt:207 */
   14     19   
        &self.0
          20  +
        /* ClientEnumGenerator.kt:206 */
   15     21   
    }
          22  +
    /* ClientEnumGenerator.kt:204 */
   16     23   
}
          24  +
/* ClientEnumGenerator.kt:210 */
   17     25   
impl ::std::fmt::Display for UnknownVariantValue {
   18     26   
    fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
   19     27   
        write!(f, "{}", self.0)
   20     28   
    }
   21     29   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* ResponseDeserializerGenerator.kt:170 */
    2      3   
pub(crate) fn type_erase_result<O, E>(
    3      4   
    result: ::std::result::Result<O, E>,
    4      5   
) -> ::std::result::Result<
    5      6   
    ::aws_smithy_runtime_api::client::interceptors::context::Output,
    6      7   
    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError<::aws_smithy_runtime_api::client::interceptors::context::Error>,
    7      8   
>
    8      9   
where
    9     10   
    O: ::std::fmt::Debug + ::std::marker::Send + ::std::marker::Sync + 'static,
   10     11   
    E: ::std::error::Error + std::fmt::Debug + ::std::marker::Send + ::std::marker::Sync + 'static,
   11     12   
{

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_blob_list.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:616 */
    2      3   
pub(crate) fn de_blob_list(
    3      4   
    decoder: &mut ::aws_smithy_cbor::Decoder,
    4      5   
) -> ::std::result::Result<::std::vec::Vec<::aws_smithy_types::Blob>, ::aws_smithy_cbor::decode::DeserializeError> {
    5      6   
    fn member(
    6      7   
        mut list: ::std::vec::Vec<::aws_smithy_types::Blob>,
    7      8   
        decoder: &mut ::aws_smithy_cbor::Decoder,
    8      9   
    ) -> ::std::result::Result<::std::vec::Vec<::aws_smithy_types::Blob>, ::aws_smithy_cbor::decode::DeserializeError> {
    9     10   
        let value = match decoder.datatype()? {
   10     11   
            ::aws_smithy_cbor::data::Type::Null => {
   11     12   
                decoder.null()?;

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_boolean_list.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:616 */
    2      3   
pub(crate) fn de_boolean_list(
    3      4   
    decoder: &mut ::aws_smithy_cbor::Decoder,
    4      5   
) -> ::std::result::Result<::std::vec::Vec<bool>, ::aws_smithy_cbor::decode::DeserializeError> {
    5      6   
    fn member(
    6      7   
        mut list: ::std::vec::Vec<bool>,
    7      8   
        decoder: &mut ::aws_smithy_cbor::Decoder,
    8      9   
    ) -> ::std::result::Result<::std::vec::Vec<bool>, ::aws_smithy_cbor::decode::DeserializeError> {
    9     10   
        let value = match decoder.datatype()? {
   10     11   
            ::aws_smithy_cbor::data::Type::Null => {
   11     12   
                decoder.null()?;

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_client_optional_defaults.rs

@@ -1,1 +12,20 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborSerializerGenerator.kt:369 */
    2      3   
pub fn ser_client_optional_defaults(
    3      4   
    encoder: &mut ::aws_smithy_cbor::Encoder,
    4      5   
    #[allow(unused)] input: &crate::types::ClientOptionalDefaults,
    5      6   
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
           7  +
    /* CborSerializerGenerator.kt:377 */
    6      8   
    encoder.begin_map();
           9  +
    /* CborSerializerGenerator.kt:414 */
    7     10   
    if let Some(var_1) = &input.member {
          11  +
        /* CborSerializerGenerator.kt:466 */
    8     12   
        encoder.str("member").integer(*var_1);
          13  +
        /* CborSerializerGenerator.kt:414 */
    9     14   
    }
          15  +
    /* CborSerializerGenerator.kt:393 */
   10     16   
    encoder.end();
          17  +
    /* CborSerializerGenerator.kt:394 */
   11     18   
    Ok(())
          19  +
    /* CborSerializerGenerator.kt:369 */
   12     20   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_complex_error.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:482 */
    2      3   
pub(crate) fn de_complex_error_cbor_err(
    3      4   
    value: &[u8],
    4      5   
    mut builder: crate::types::error::builders::ComplexErrorBuilder,
    5      6   
) -> ::std::result::Result<crate::types::error::builders::ComplexErrorBuilder, ::aws_smithy_cbor::decode::DeserializeError> {
    6      7   
    #[allow(clippy::match_single_binding)]
    7      8   
    fn pair(
    8      9   
        mut builder: crate::types::error::builders::ComplexErrorBuilder,
    9     10   
        decoder: &mut ::aws_smithy_cbor::Decoder,
   10     11   
    ) -> ::std::result::Result<crate::types::error::builders::ComplexErrorBuilder, ::aws_smithy_cbor::decode::DeserializeError> {
   11     12   
        builder = match decoder.str()?.as_ref() {

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_complex_nested_error_data.rs

@@ -1,1 +44,51 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:692 */
    2      3   
pub(crate) fn de_complex_nested_error_data(
    3      4   
    decoder: &mut ::aws_smithy_cbor::Decoder,
    4      5   
) -> ::std::result::Result<crate::types::ComplexNestedErrorData, ::aws_smithy_cbor::decode::DeserializeError> {
           6  +
    /* CborParserGenerator.kt:700 */
    5      7   
    #[allow(clippy::match_single_binding)]
    6      8   
    fn pair(
    7      9   
        mut builder: crate::types::builders::ComplexNestedErrorDataBuilder,
    8     10   
        decoder: &mut ::aws_smithy_cbor::Decoder,
    9     11   
    ) -> ::std::result::Result<crate::types::builders::ComplexNestedErrorDataBuilder, ::aws_smithy_cbor::decode::DeserializeError> {
   10     12   
        builder = match decoder.str()?.as_ref() {
   11     13   
            "Foo" => ::aws_smithy_cbor::decode::set_optional(builder, decoder, |builder, decoder| Ok(builder.set_foo(Some(decoder.string()?))))?,
   12     14   
            _ => {
   13     15   
                decoder.skip()?;
   14     16   
                builder
   15     17   
            }
   16     18   
        };
   17     19   
        Ok(builder)
   18     20   
    }
   19     21   
   20     22   
    let mut builder = crate::types::builders::ComplexNestedErrorDataBuilder::default();
   21     23   
   22     24   
    match decoder.map()? {
   23     25   
        None => loop {
   24     26   
            match decoder.datatype()? {
   25     27   
                ::aws_smithy_cbor::data::Type::Break => {
   26     28   
                    decoder.skip()?;
   27     29   
                    break;
   28     30   
                }
   29     31   
                _ => {
   30     32   
                    builder = pair(builder, decoder)?;
   31     33   
                }
   32     34   
            };
   33     35   
        },
   34     36   
        Some(n) => {
   35     37   
            for _ in 0..n {
   36     38   
                builder = pair(builder, decoder)?;
   37     39   
            }
   38     40   
        }
   39     41   
    };
          42  +
    /* CborParserGenerator.kt:726 */
   40     43   
    #[allow(clippy::needless_question_mark)]
          44  +
    /* CborParserGenerator.kt:727 */
   41     45   
    {
          46  +
        /* CborParserGenerator.kt:728 */
   42     47   
        return Ok(builder.build());
          48  +
        /* CborParserGenerator.kt:727 */
   43     49   
    }
          50  +
    /* CborParserGenerator.kt:692 */
   44     51   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_defaults.rs

@@ -1,1 +90,176 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborSerializerGenerator.kt:369 */
    2      3   
pub fn ser_defaults(
    3      4   
    encoder: &mut ::aws_smithy_cbor::Encoder,
    4      5   
    #[allow(unused)] input: &crate::types::Defaults,
    5      6   
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
           7  +
    /* CborSerializerGenerator.kt:377 */
    6      8   
    encoder.begin_map();
           9  +
    /* SerializerUtil.kt:46 */
    7     10   
    {
          11  +
        /* CborSerializerGenerator.kt:462 */
    8     12   
        encoder.str("defaultString").str(input.default_string.as_str());
          13  +
        /* SerializerUtil.kt:46 */
    9     14   
    }
          15  +
    /* SerializerUtil.kt:46 */
   10     16   
    if !input.default_boolean {
          17  +
        /* CborSerializerGenerator.kt:460 */
   11     18   
        encoder.str("defaultBoolean").boolean(input.default_boolean);
          19  +
        /* SerializerUtil.kt:46 */
   12     20   
    }
          21  +
    /* SerializerUtil.kt:46 */
   13     22   
    {
          23  +
        /* CborSerializerGenerator.kt:486 */
   14     24   
        encoder.str("defaultList");
          25  +
        /* CborSerializerGenerator.kt:504 */
   15     26   
        encoder.array((input.default_list).len());
          27  +
        /* CborSerializerGenerator.kt:506 */
   16     28   
        for item_1 in &input.default_list {
          29  +
            /* SerializerUtil.kt:42 */
   17     30   
            {
          31  +
                /* CborSerializerGenerator.kt:462 */
   18     32   
                encoder.str(item_1.as_str());
          33  +
                /* SerializerUtil.kt:42 */
   19     34   
            }
          35  +
            /* CborSerializerGenerator.kt:506 */
   20     36   
        }
          37  +
        /* SerializerUtil.kt:46 */
   21     38   
    }
          39  +
    /* SerializerUtil.kt:46 */
   22     40   
    {
          41  +
        /* CborSerializerGenerator.kt:472 */
   23     42   
        encoder.str("defaultTimestamp").timestamp(&input.default_timestamp);
          43  +
        /* SerializerUtil.kt:46 */
   24     44   
    }
          45  +
    /* SerializerUtil.kt:46 */
   25     46   
    {
          47  +
        /* CborSerializerGenerator.kt:459 */
   26     48   
        encoder.str("defaultBlob").blob(&input.default_blob);
          49  +
        /* SerializerUtil.kt:46 */
   27     50   
    }
          51  +
    /* SerializerUtil.kt:46 */
   28     52   
    if input.default_byte != 1 {
          53  +
        /* CborSerializerGenerator.kt:464 */
   29     54   
        encoder.str("defaultByte").byte(input.default_byte);
          55  +
        /* SerializerUtil.kt:46 */
   30     56   
    }
          57  +
    /* SerializerUtil.kt:46 */
   31     58   
    if input.default_short != 1 {
          59  +
        /* CborSerializerGenerator.kt:465 */
   32     60   
        encoder.str("defaultShort").short(input.default_short);
          61  +
        /* SerializerUtil.kt:46 */
   33     62   
    }
          63  +
    /* SerializerUtil.kt:46 */
   34     64   
    if input.default_integer != 10 {
          65  +
        /* CborSerializerGenerator.kt:466 */
   35     66   
        encoder.str("defaultInteger").integer(input.default_integer);
          67  +
        /* SerializerUtil.kt:46 */
   36     68   
    }
          69  +
    /* SerializerUtil.kt:46 */
   37     70   
    if input.default_long != 100 {
          71  +
        /* CborSerializerGenerator.kt:467 */
   38     72   
        encoder.str("defaultLong").long(input.default_long);
          73  +
        /* SerializerUtil.kt:46 */
   39     74   
    }
          75  +
    /* SerializerUtil.kt:46 */
   40     76   
    if input.default_float != 1.0 {
          77  +
        /* CborSerializerGenerator.kt:469 */
   41     78   
        encoder.str("defaultFloat").float(input.default_float);
          79  +
        /* SerializerUtil.kt:46 */
   42     80   
    }
          81  +
    /* SerializerUtil.kt:46 */
   43     82   
    if input.default_double != 1.0 {
          83  +
        /* CborSerializerGenerator.kt:470 */
   44     84   
        encoder.str("defaultDouble").double(input.default_double);
          85  +
        /* SerializerUtil.kt:46 */
   45     86   
    }
          87  +
    /* SerializerUtil.kt:46 */
   46     88   
    {
          89  +
        /* CborSerializerGenerator.kt:486 */
   47     90   
        encoder.str("defaultMap");
          91  +
        /* CborSerializerGenerator.kt:517 */
   48     92   
        encoder.map((input.default_map).len());
          93  +
        /* CborSerializerGenerator.kt:518 */
   49     94   
        for (key_2, value_3) in &input.default_map {
          95  +
            /* SerializerUtil.kt:42 */
   50     96   
            {
          97  +
                /* CborSerializerGenerator.kt:462 */
   51     98   
                encoder.str(key_2.as_str()).str(value_3.as_str());
          99  +
                /* SerializerUtil.kt:42 */
   52    100   
            }
         101  +
            /* CborSerializerGenerator.kt:518 */
   53    102   
        }
         103  +
        /* SerializerUtil.kt:46 */
   54    104   
    }
         105  +
    /* SerializerUtil.kt:46 */
   55    106   
    {
         107  +
        /* CborSerializerGenerator.kt:462 */
   56    108   
        encoder.str("defaultEnum").str(input.default_enum.as_str());
         109  +
        /* SerializerUtil.kt:46 */
   57    110   
    }
         111  +
    /* SerializerUtil.kt:46 */
   58    112   
    if input.default_int_enum != 1 {
         113  +
        /* CborSerializerGenerator.kt:466 */
   59    114   
        encoder.str("defaultIntEnum").integer(input.default_int_enum);
         115  +
        /* SerializerUtil.kt:46 */
   60    116   
    }
         117  +
    /* SerializerUtil.kt:46 */
   61    118   
    {
         119  +
        /* CborSerializerGenerator.kt:462 */
   62    120   
        encoder.str("emptyString").str(input.empty_string.as_str());
         121  +
        /* SerializerUtil.kt:46 */
   63    122   
    }
         123  +
    /* SerializerUtil.kt:46 */
   64    124   
    if input.false_boolean {
         125  +
        /* CborSerializerGenerator.kt:460 */
   65    126   
        encoder.str("falseBoolean").boolean(input.false_boolean);
         127  +
        /* SerializerUtil.kt:46 */
   66    128   
    }
         129  +
    /* SerializerUtil.kt:46 */
   67    130   
    {
         131  +
        /* CborSerializerGenerator.kt:459 */
   68    132   
        encoder.str("emptyBlob").blob(&input.empty_blob);
         133  +
        /* SerializerUtil.kt:46 */
   69    134   
    }
         135  +
    /* SerializerUtil.kt:46 */
   70    136   
    if input.zero_byte != 0 {
         137  +
        /* CborSerializerGenerator.kt:464 */
   71    138   
        encoder.str("zeroByte").byte(input.zero_byte);
         139  +
        /* SerializerUtil.kt:46 */
   72    140   
    }
         141  +
    /* SerializerUtil.kt:46 */
   73    142   
    if input.zero_short != 0 {
         143  +
        /* CborSerializerGenerator.kt:465 */
   74    144   
        encoder.str("zeroShort").short(input.zero_short);
         145  +
        /* SerializerUtil.kt:46 */
   75    146   
    }
         147  +
    /* SerializerUtil.kt:46 */
   76    148   
    if input.zero_integer != 0 {
         149  +
        /* CborSerializerGenerator.kt:466 */
   77    150   
        encoder.str("zeroInteger").integer(input.zero_integer);
         151  +
        /* SerializerUtil.kt:46 */
   78    152   
    }
         153  +
    /* SerializerUtil.kt:46 */
   79    154   
    if input.zero_long != 0 {
         155  +
        /* CborSerializerGenerator.kt:467 */
   80    156   
        encoder.str("zeroLong").long(input.zero_long);
         157  +
        /* SerializerUtil.kt:46 */
   81    158   
    }
         159  +
    /* SerializerUtil.kt:46 */
   82    160   
    if input.zero_float != 0.0 {
         161  +
        /* CborSerializerGenerator.kt:469 */
   83    162   
        encoder.str("zeroFloat").float(input.zero_float);
         163  +
        /* SerializerUtil.kt:46 */
   84    164   
    }
         165  +
    /* SerializerUtil.kt:46 */
   85    166   
    if input.zero_double != 0.0 {
         167  +
        /* CborSerializerGenerator.kt:470 */
   86    168   
        encoder.str("zeroDouble").double(input.zero_double);
         169  +
        /* SerializerUtil.kt:46 */
   87    170   
    }
         171  +
    /* CborSerializerGenerator.kt:393 */
   88    172   
    encoder.end();
         173  +
    /* CborSerializerGenerator.kt:394 */
   89    174   
    Ok(())
         175  +
    /* CborSerializerGenerator.kt:369 */
   90    176   
}

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_dense_boolean_map.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:659 */
    2      3   
pub(crate) fn de_dense_boolean_map(
    3      4   
    decoder: &mut ::aws_smithy_cbor::Decoder,
    4      5   
) -> ::std::result::Result<::std::collections::HashMap<::std::string::String, bool>, ::aws_smithy_cbor::decode::DeserializeError> {
    5      6   
    fn pair(
    6      7   
        mut map: ::std::collections::HashMap<::std::string::String, bool>,
    7      8   
        decoder: &mut ::aws_smithy_cbor::Decoder,
    8      9   
    ) -> ::std::result::Result<::std::collections::HashMap<::std::string::String, bool>, ::aws_smithy_cbor::decode::DeserializeError> {
    9     10   
        let key = decoder.string()?;
   10     11   
        let value = match decoder.datatype()? {
   11     12   
            ::aws_smithy_cbor::data::Type::Null => {

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_dense_number_map.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:659 */
    2      3   
pub(crate) fn de_dense_number_map(
    3      4   
    decoder: &mut ::aws_smithy_cbor::Decoder,
    4      5   
) -> ::std::result::Result<::std::collections::HashMap<::std::string::String, i32>, ::aws_smithy_cbor::decode::DeserializeError> {
    5      6   
    fn pair(
    6      7   
        mut map: ::std::collections::HashMap<::std::string::String, i32>,
    7      8   
        decoder: &mut ::aws_smithy_cbor::Decoder,
    8      9   
    ) -> ::std::result::Result<::std::collections::HashMap<::std::string::String, i32>, ::aws_smithy_cbor::decode::DeserializeError> {
    9     10   
        let key = decoder.string()?;
   10     11   
        let value = match decoder.datatype()? {
   11     12   
            ::aws_smithy_cbor::data::Type::Null => {

tmp-codegen-diff/codegen-client-test/rpcv2Cbor/rust-client-codegen/src/protocol_serde/shape_dense_set_map.rs

@@ -1,1 +31,32 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
/* CborParserGenerator.kt:659 */
    2      3   
pub(crate) fn de_dense_set_map(
    3      4   
    decoder: &mut ::aws_smithy_cbor::Decoder,
    4      5   
) -> ::std::result::Result<
    5      6   
    ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
    6      7   
    ::aws_smithy_cbor::decode::DeserializeError,
    7      8   
> {
    8      9   
    fn pair(
    9     10   
        mut map: ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
   10     11   
        decoder: &mut ::aws_smithy_cbor::Decoder,
   11     12   
    ) -> ::std::result::Result<