AWS SDK

AWS SDK

rev. 96f5a1b4ad139d2f1ad1e8e40f300e1cd1ff574c

Files changed:

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_start_configuration_recorder_input.rs

@@ -1,0 +10,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_start_configuration_recorder_input_input(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::operation::start_configuration_recorder::StartConfigurationRecorderInput,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.configuration_recorder_name {
    7         -
        object.key("ConfigurationRecorderName").string(var_1.as_str());
    8         -
    }
    9         -
    Ok(())
   10         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_start_remediation_execution.rs

@@ -1,0 +155,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_start_remediation_execution_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<
    8         -
    crate::operation::start_remediation_execution::StartRemediationExecutionOutput,
    9         -
    crate::operation::start_remediation_execution::StartRemediationExecutionError,
   10         -
> {
   11         -
    #[allow(unused_mut)]
   12         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   13         -
        .map_err(crate::operation::start_remediation_execution::StartRemediationExecutionError::unhandled)?;
   14         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   15         -
    let generic = generic_builder.build();
   16         -
    let error_code = match generic.code() {
   17         -
        Some(code) => code,
   18         -
        None => {
   19         -
            return Err(crate::operation::start_remediation_execution::StartRemediationExecutionError::unhandled(
   20         -
                generic,
   21         -
            ))
   22         -
        }
   23         -
    };
   24         -
   25         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   26         -
    Err(match error_code {
   27         -
        "InsufficientPermissionsException" => {
   28         -
            crate::operation::start_remediation_execution::StartRemediationExecutionError::InsufficientPermissionsException({
   29         -
                #[allow(unused_mut)]
   30         -
                let mut tmp = {
   31         -
                    #[allow(unused_mut)]
   32         -
                    let mut output = crate::types::error::builders::InsufficientPermissionsExceptionBuilder::default();
   33         -
                    output = crate::protocol_serde::shape_insufficient_permissions_exception::de_insufficient_permissions_exception_json_err(
   34         -
                        _response_body,
   35         -
                        output,
   36         -
                    )
   37         -
                    .map_err(crate::operation::start_remediation_execution::StartRemediationExecutionError::unhandled)?;
   38         -
                    let output = output.meta(generic);
   39         -
                    output.build()
   40         -
                };
   41         -
                if tmp.message.is_none() {
   42         -
                    tmp.message = _error_message;
   43         -
                }
   44         -
                tmp
   45         -
            })
   46         -
        }
   47         -
        "InvalidParameterValueException" => {
   48         -
            crate::operation::start_remediation_execution::StartRemediationExecutionError::InvalidParameterValueException({
   49         -
                #[allow(unused_mut)]
   50         -
                let mut tmp = {
   51         -
                    #[allow(unused_mut)]
   52         -
                    let mut output = crate::types::error::builders::InvalidParameterValueExceptionBuilder::default();
   53         -
                    output = crate::protocol_serde::shape_invalid_parameter_value_exception::de_invalid_parameter_value_exception_json_err(
   54         -
                        _response_body,
   55         -
                        output,
   56         -
                    )
   57         -
                    .map_err(crate::operation::start_remediation_execution::StartRemediationExecutionError::unhandled)?;
   58         -
                    let output = output.meta(generic);
   59         -
                    output.build()
   60         -
                };
   61         -
                if tmp.message.is_none() {
   62         -
                    tmp.message = _error_message;
   63         -
                }
   64         -
                tmp
   65         -
            })
   66         -
        }
   67         -
        "NoSuchRemediationConfigurationException" => {
   68         -
            crate::operation::start_remediation_execution::StartRemediationExecutionError::NoSuchRemediationConfigurationException({
   69         -
                #[allow(unused_mut)]
   70         -
                let mut tmp = {
   71         -
                    #[allow(unused_mut)]
   72         -
                    let mut output = crate::types::error::builders::NoSuchRemediationConfigurationExceptionBuilder::default();
   73         -
                    output = crate::protocol_serde::shape_no_such_remediation_configuration_exception::de_no_such_remediation_configuration_exception_json_err(_response_body, output).map_err(crate::operation::start_remediation_execution::StartRemediationExecutionError::unhandled)?;
   74         -
                    let output = output.meta(generic);
   75         -
                    output.build()
   76         -
                };
   77         -
                if tmp.message.is_none() {
   78         -
                    tmp.message = _error_message;
   79         -
                }
   80         -
                tmp
   81         -
            })
   82         -
        }
   83         -
        _ => crate::operation::start_remediation_execution::StartRemediationExecutionError::generic(generic),
   84         -
    })
   85         -
}
   86         -
   87         -
#[allow(clippy::unnecessary_wraps)]
   88         -
pub fn de_start_remediation_execution_http_response(
   89         -
    _response_status: u16,
   90         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   91         -
    _response_body: &[u8],
   92         -
) -> std::result::Result<
   93         -
    crate::operation::start_remediation_execution::StartRemediationExecutionOutput,
   94         -
    crate::operation::start_remediation_execution::StartRemediationExecutionError,
   95         -
> {
   96         -
    Ok({
   97         -
        #[allow(unused_mut)]
   98         -
        let mut output = crate::operation::start_remediation_execution::builders::StartRemediationExecutionOutputBuilder::default();
   99         -
        output = crate::protocol_serde::shape_start_remediation_execution::de_start_remediation_execution(_response_body, output)
  100         -
            .map_err(crate::operation::start_remediation_execution::StartRemediationExecutionError::unhandled)?;
  101         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
  102         -
        output.build()
  103         -
    })
  104         -
}
  105         -
  106         -
pub fn ser_start_remediation_execution_input(
  107         -
    input: &crate::operation::start_remediation_execution::StartRemediationExecutionInput,
  108         -
) -> ::std::result::Result<::aws_smithy_types::body::SdkBody, ::aws_smithy_types::error::operation::SerializationError> {
  109         -
    let mut out = String::new();
  110         -
    let mut object = ::aws_smithy_json::serialize::JsonObjectWriter::new(&mut out);
  111         -
    crate::protocol_serde::shape_start_remediation_execution_input::ser_start_remediation_execution_input_input(&mut object, input)?;
  112         -
    object.finish();
  113         -
    Ok(::aws_smithy_types::body::SdkBody::from(out))
  114         -
}
  115         -
  116         -
pub(crate) fn de_start_remediation_execution(
  117         -
    _value: &[u8],
  118         -
    mut builder: crate::operation::start_remediation_execution::builders::StartRemediationExecutionOutputBuilder,
  119         -
) -> ::std::result::Result<
  120         -
    crate::operation::start_remediation_execution::builders::StartRemediationExecutionOutputBuilder,
  121         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
  122         -
> {
  123         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  124         -
    let tokens = &mut tokens_owned;
  125         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  126         -
    loop {
  127         -
        match tokens.next().transpose()? {
  128         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  129         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  130         -
                "FailureMessage" => {
  131         -
                    builder = builder.set_failure_message(
  132         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  133         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  134         -
                            .transpose()?,
  135         -
                    );
  136         -
                }
  137         -
                "FailedItems" => {
  138         -
                    builder = builder.set_failed_items(crate::protocol_serde::shape_resource_keys::de_resource_keys(tokens, _value)?);
  139         -
                }
  140         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  141         -
            },
  142         -
            other => {
  143         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  144         -
                    "expected object key or end object, found: {other:?}"
  145         -
                )))
  146         -
            }
  147         -
        }
  148         -
    }
  149         -
    if tokens.next().is_some() {
  150         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  151         -
            "found more JSON tokens after completing parsing",
  152         -
        ));
  153         -
    }
  154         -
    Ok(builder)
  155         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_start_remediation_execution_input.rs

@@ -1,0 +22,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_start_remediation_execution_input_input(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::operation::start_remediation_execution::StartRemediationExecutionInput,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.config_rule_name {
    7         -
        object.key("ConfigRuleName").string(var_1.as_str());
    8         -
    }
    9         -
    if let Some(var_2) = &input.resource_keys {
   10         -
        let mut array_3 = object.key("ResourceKeys").start_array();
   11         -
        for item_4 in var_2 {
   12         -
            {
   13         -
                #[allow(unused_mut)]
   14         -
                let mut object_5 = array_3.value().start_object();
   15         -
                crate::protocol_serde::shape_resource_key::ser_resource_key(&mut object_5, item_4)?;
   16         -
                object_5.finish();
   17         -
            }
   18         -
        }
   19         -
        array_3.finish();
   20         -
    }
   21         -
    Ok(())
   22         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_start_resource_evaluation.rs

@@ -1,0 +132,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_start_resource_evaluation_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<
    8         -
    crate::operation::start_resource_evaluation::StartResourceEvaluationOutput,
    9         -
    crate::operation::start_resource_evaluation::StartResourceEvaluationError,
   10         -
> {
   11         -
    #[allow(unused_mut)]
   12         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   13         -
        .map_err(crate::operation::start_resource_evaluation::StartResourceEvaluationError::unhandled)?;
   14         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   15         -
    let generic = generic_builder.build();
   16         -
    let error_code = match generic.code() {
   17         -
        Some(code) => code,
   18         -
        None => {
   19         -
            return Err(crate::operation::start_resource_evaluation::StartResourceEvaluationError::unhandled(
   20         -
                generic,
   21         -
            ))
   22         -
        }
   23         -
    };
   24         -
   25         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   26         -
    Err(match error_code {
   27         -
        "IdempotentParameterMismatch" => crate::operation::start_resource_evaluation::StartResourceEvaluationError::IdempotentParameterMismatch({
   28         -
            #[allow(unused_mut)]
   29         -
            let mut tmp = {
   30         -
                #[allow(unused_mut)]
   31         -
                let mut output = crate::types::error::builders::IdempotentParameterMismatchBuilder::default();
   32         -
                output =
   33         -
                    crate::protocol_serde::shape_idempotent_parameter_mismatch::de_idempotent_parameter_mismatch_json_err(_response_body, output)
   34         -
                        .map_err(crate::operation::start_resource_evaluation::StartResourceEvaluationError::unhandled)?;
   35         -
                let output = output.meta(generic);
   36         -
                output.build()
   37         -
            };
   38         -
            if tmp.message.is_none() {
   39         -
                tmp.message = _error_message;
   40         -
            }
   41         -
            tmp
   42         -
        }),
   43         -
        "InvalidParameterValueException" => {
   44         -
            crate::operation::start_resource_evaluation::StartResourceEvaluationError::InvalidParameterValueException({
   45         -
                #[allow(unused_mut)]
   46         -
                let mut tmp = {
   47         -
                    #[allow(unused_mut)]
   48         -
                    let mut output = crate::types::error::builders::InvalidParameterValueExceptionBuilder::default();
   49         -
                    output = crate::protocol_serde::shape_invalid_parameter_value_exception::de_invalid_parameter_value_exception_json_err(
   50         -
                        _response_body,
   51         -
                        output,
   52         -
                    )
   53         -
                    .map_err(crate::operation::start_resource_evaluation::StartResourceEvaluationError::unhandled)?;
   54         -
                    let output = output.meta(generic);
   55         -
                    output.build()
   56         -
                };
   57         -
                if tmp.message.is_none() {
   58         -
                    tmp.message = _error_message;
   59         -
                }
   60         -
                tmp
   61         -
            })
   62         -
        }
   63         -
        _ => crate::operation::start_resource_evaluation::StartResourceEvaluationError::generic(generic),
   64         -
    })
   65         -
}
   66         -
   67         -
#[allow(clippy::unnecessary_wraps)]
   68         -
pub fn de_start_resource_evaluation_http_response(
   69         -
    _response_status: u16,
   70         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   71         -
    _response_body: &[u8],
   72         -
) -> std::result::Result<
   73         -
    crate::operation::start_resource_evaluation::StartResourceEvaluationOutput,
   74         -
    crate::operation::start_resource_evaluation::StartResourceEvaluationError,
   75         -
> {
   76         -
    Ok({
   77         -
        #[allow(unused_mut)]
   78         -
        let mut output = crate::operation::start_resource_evaluation::builders::StartResourceEvaluationOutputBuilder::default();
   79         -
        output = crate::protocol_serde::shape_start_resource_evaluation::de_start_resource_evaluation(_response_body, output)
   80         -
            .map_err(crate::operation::start_resource_evaluation::StartResourceEvaluationError::unhandled)?;
   81         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
   82         -
        output.build()
   83         -
    })
   84         -
}
   85         -
   86         -
pub fn ser_start_resource_evaluation_input(
   87         -
    input: &crate::operation::start_resource_evaluation::StartResourceEvaluationInput,
   88         -
) -> ::std::result::Result<::aws_smithy_types::body::SdkBody, ::aws_smithy_types::error::operation::SerializationError> {
   89         -
    let mut out = String::new();
   90         -
    let mut object = ::aws_smithy_json::serialize::JsonObjectWriter::new(&mut out);
   91         -
    crate::protocol_serde::shape_start_resource_evaluation_input::ser_start_resource_evaluation_input_input(&mut object, input)?;
   92         -
    object.finish();
   93         -
    Ok(::aws_smithy_types::body::SdkBody::from(out))
   94         -
}
   95         -
   96         -
pub(crate) fn de_start_resource_evaluation(
   97         -
    _value: &[u8],
   98         -
    mut builder: crate::operation::start_resource_evaluation::builders::StartResourceEvaluationOutputBuilder,
   99         -
) -> ::std::result::Result<
  100         -
    crate::operation::start_resource_evaluation::builders::StartResourceEvaluationOutputBuilder,
  101         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
  102         -
> {
  103         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  104         -
    let tokens = &mut tokens_owned;
  105         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  106         -
    loop {
  107         -
        match tokens.next().transpose()? {
  108         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  109         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  110         -
                "ResourceEvaluationId" => {
  111         -
                    builder = builder.set_resource_evaluation_id(
  112         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  113         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  114         -
                            .transpose()?,
  115         -
                    );
  116         -
                }
  117         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  118         -
            },
  119         -
            other => {
  120         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  121         -
                    "expected object key or end object, found: {other:?}"
  122         -
                )))
  123         -
            }
  124         -
        }
  125         -
    }
  126         -
    if tokens.next().is_some() {
  127         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  128         -
            "found more JSON tokens after completing parsing",
  129         -
        ));
  130         -
    }
  131         -
    Ok(builder)
  132         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_start_resource_evaluation_input.rs

@@ -1,0 +31,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_start_resource_evaluation_input_input(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::operation::start_resource_evaluation::StartResourceEvaluationInput,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.resource_details {
    7         -
        #[allow(unused_mut)]
    8         -
        let mut object_2 = object.key("ResourceDetails").start_object();
    9         -
        crate::protocol_serde::shape_resource_details::ser_resource_details(&mut object_2, var_1)?;
   10         -
        object_2.finish();
   11         -
    }
   12         -
    if let Some(var_3) = &input.evaluation_context {
   13         -
        #[allow(unused_mut)]
   14         -
        let mut object_4 = object.key("EvaluationContext").start_object();
   15         -
        crate::protocol_serde::shape_evaluation_context::ser_evaluation_context(&mut object_4, var_3)?;
   16         -
        object_4.finish();
   17         -
    }
   18         -
    if let Some(var_5) = &input.evaluation_mode {
   19         -
        object.key("EvaluationMode").string(var_5.as_str());
   20         -
    }
   21         -
    if let Some(var_6) = &input.evaluation_timeout {
   22         -
        object.key("EvaluationTimeout").number(
   23         -
            #[allow(clippy::useless_conversion)]
   24         -
            ::aws_smithy_types::Number::NegInt((*var_6).into()),
   25         -
        );
   26         -
    }
   27         -
    if let Some(var_7) = &input.client_token {
   28         -
        object.key("ClientToken").string(var_7.as_str());
   29         -
    }
   30         -
    Ok(())
   31         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_static_parameter_values.rs

@@ -1,0 +39,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_static_parameter_values<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<::std::vec::Vec<::std::string::String>>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   12         -
            let mut items = Vec::new();
   13         -
            loop {
   14         -
                match tokens.peek() {
   15         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   16         -
                        tokens.next().transpose().unwrap();
   17         -
                        break;
   18         -
                    }
   19         -
                    _ => {
   20         -
                        let value = ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                            .transpose()?;
   23         -
                        if let Some(value) = value {
   24         -
                            items.push(value);
   25         -
                        } else {
   26         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   27         -
                                "dense list cannot contain null values",
   28         -
                            ));
   29         -
                        }
   30         -
                    }
   31         -
                }
   32         -
            }
   33         -
            Ok(Some(items))
   34         -
        }
   35         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   36         -
            "expected start array or null",
   37         -
        )),
   38         -
    }
   39         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_static_value.rs

@@ -1,0 +56,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_static_value(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::StaticValue,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    {
    7         -
        let mut array_1 = object.key("Values").start_array();
    8         -
        for item_2 in &input.values {
    9         -
            {
   10         -
                array_1.value().string(item_2.as_str());
   11         -
            }
   12         -
        }
   13         -
        array_1.finish();
   14         -
    }
   15         -
    Ok(())
   16         -
}
   17         -
   18         -
pub(crate) fn de_static_value<'a, I>(
   19         -
    tokens: &mut ::std::iter::Peekable<I>,
   20         -
    _value: &'a [u8],
   21         -
) -> ::std::result::Result<Option<crate::types::StaticValue>, ::aws_smithy_json::deserialize::error::DeserializeError>
   22         -
where
   23         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   24         -
{
   25         -
    match tokens.next().transpose()? {
   26         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   27         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   28         -
            #[allow(unused_mut)]
   29         -
            let mut builder = crate::types::builders::StaticValueBuilder::default();
   30         -
            loop {
   31         -
                match tokens.next().transpose()? {
   32         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   33         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   34         -
                        "Values" => {
   35         -
                            builder = builder.set_values(crate::protocol_serde::shape_static_parameter_values::de_static_parameter_values(
   36         -
                                tokens, _value,
   37         -
                            )?);
   38         -
                        }
   39         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   40         -
                    },
   41         -
                    other => {
   42         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   43         -
                            "expected object key or end object, found: {other:?}"
   44         -
                        )))
   45         -
                    }
   46         -
                }
   47         -
            }
   48         -
            Ok(Some(crate::serde_util::static_value_correct_errors(builder).build().map_err(|err| {
   49         -
                ::aws_smithy_json::deserialize::error::DeserializeError::custom_source("Response was invalid", err)
   50         -
            })?))
   51         -
        }
   52         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   53         -
            "expected start object or null",
   54         -
        )),
   55         -
    }
   56         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_status_detail_filters.rs

@@ -1,0 +13,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_status_detail_filters(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::StatusDetailFilters,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.account_id {
    7         -
        object.key("AccountId").string(var_1.as_str());
    8         -
    }
    9         -
    if let Some(var_2) = &input.member_account_rule_status {
   10         -
        object.key("MemberAccountRuleStatus").string(var_2.as_str());
   11         -
    }
   12         -
    Ok(())
   13         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_stop_configuration_recorder.rs

@@ -1,0 +95,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_stop_configuration_recorder_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<
    8         -
    crate::operation::stop_configuration_recorder::StopConfigurationRecorderOutput,
    9         -
    crate::operation::stop_configuration_recorder::StopConfigurationRecorderError,
   10         -
> {
   11         -
    #[allow(unused_mut)]
   12         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   13         -
        .map_err(crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::unhandled)?;
   14         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   15         -
    let generic = generic_builder.build();
   16         -
    let error_code = match generic.code() {
   17         -
        Some(code) => code,
   18         -
        None => {
   19         -
            return Err(crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::unhandled(
   20         -
                generic,
   21         -
            ))
   22         -
        }
   23         -
    };
   24         -
   25         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   26         -
    Err(match error_code {
   27         -
        "NoSuchConfigurationRecorderException" => {
   28         -
            crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::NoSuchConfigurationRecorderException({
   29         -
                #[allow(unused_mut)]
   30         -
                let mut tmp = {
   31         -
                    #[allow(unused_mut)]
   32         -
                    let mut output = crate::types::error::builders::NoSuchConfigurationRecorderExceptionBuilder::default();
   33         -
                    output =
   34         -
                        crate::protocol_serde::shape_no_such_configuration_recorder_exception::de_no_such_configuration_recorder_exception_json_err(
   35         -
                            _response_body,
   36         -
                            output,
   37         -
                        )
   38         -
                        .map_err(crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::unhandled)?;
   39         -
                    let output = output.meta(generic);
   40         -
                    output.build()
   41         -
                };
   42         -
                if tmp.message.is_none() {
   43         -
                    tmp.message = _error_message;
   44         -
                }
   45         -
                tmp
   46         -
            })
   47         -
        }
   48         -
        "UnmodifiableEntityException" => {
   49         -
            crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::UnmodifiableEntityException({
   50         -
                #[allow(unused_mut)]
   51         -
                let mut tmp = {
   52         -
                    #[allow(unused_mut)]
   53         -
                    let mut output = crate::types::error::builders::UnmodifiableEntityExceptionBuilder::default();
   54         -
                    output =
   55         -
                        crate::protocol_serde::shape_unmodifiable_entity_exception::de_unmodifiable_entity_exception_json_err(_response_body, output)
   56         -
                            .map_err(crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::unhandled)?;
   57         -
                    let output = output.meta(generic);
   58         -
                    output.build()
   59         -
                };
   60         -
                if tmp.message.is_none() {
   61         -
                    tmp.message = _error_message;
   62         -
                }
   63         -
                tmp
   64         -
            })
   65         -
        }
   66         -
        _ => crate::operation::stop_configuration_recorder::StopConfigurationRecorderError::generic(generic),
   67         -
    })
   68         -
}
   69         -
   70         -
#[allow(clippy::unnecessary_wraps)]
   71         -
pub fn de_stop_configuration_recorder_http_response(
   72         -
    _response_status: u16,
   73         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   74         -
    _response_body: &[u8],
   75         -
) -> std::result::Result<
   76         -
    crate::operation::stop_configuration_recorder::StopConfigurationRecorderOutput,
   77         -
    crate::operation::stop_configuration_recorder::StopConfigurationRecorderError,
   78         -
> {
   79         -
    Ok({
   80         -
        #[allow(unused_mut)]
   81         -
        let mut output = crate::operation::stop_configuration_recorder::builders::StopConfigurationRecorderOutputBuilder::default();
   82         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
   83         -
        output.build()
   84         -
    })
   85         -
}
   86         -
   87         -
pub fn ser_stop_configuration_recorder_input(
   88         -
    input: &crate::operation::stop_configuration_recorder::StopConfigurationRecorderInput,
   89         -
) -> ::std::result::Result<::aws_smithy_types::body::SdkBody, ::aws_smithy_types::error::operation::SerializationError> {
   90         -
    let mut out = String::new();
   91         -
    let mut object = ::aws_smithy_json::serialize::JsonObjectWriter::new(&mut out);
   92         -
    crate::protocol_serde::shape_stop_configuration_recorder_input::ser_stop_configuration_recorder_input_input(&mut object, input)?;
   93         -
    object.finish();
   94         -
    Ok(::aws_smithy_types::body::SdkBody::from(out))
   95         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_stop_configuration_recorder_input.rs

@@ -1,0 +10,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_stop_configuration_recorder_input_input(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::operation::stop_configuration_recorder::StopConfigurationRecorderInput,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.configuration_recorder_name {
    7         -
        object.key("ConfigurationRecorderName").string(var_1.as_str());
    8         -
    }
    9         -
    Ok(())
   10         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_stored_query.rs

@@ -1,0 +92,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_stored_query<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::StoredQuery>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::StoredQueryBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "QueryId" => {
   19         -
                            builder = builder.set_query_id(
   20         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                                    .transpose()?,
   23         -
                            );
   24         -
                        }
   25         -
                        "QueryArn" => {
   26         -
                            builder = builder.set_query_arn(
   27         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   28         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   29         -
                                    .transpose()?,
   30         -
                            );
   31         -
                        }
   32         -
                        "QueryName" => {
   33         -
                            builder = builder.set_query_name(
   34         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   35         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   36         -
                                    .transpose()?,
   37         -
                            );
   38         -
                        }
   39         -
                        "Description" => {
   40         -
                            builder = builder.set_description(
   41         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   42         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   43         -
                                    .transpose()?,
   44         -
                            );
   45         -
                        }
   46         -
                        "Expression" => {
   47         -
                            builder = builder.set_expression(
   48         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   49         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   50         -
                                    .transpose()?,
   51         -
                            );
   52         -
                        }
   53         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   54         -
                    },
   55         -
                    other => {
   56         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   57         -
                            "expected object key or end object, found: {other:?}"
   58         -
                        )))
   59         -
                    }
   60         -
                }
   61         -
            }
   62         -
            Ok(Some(crate::serde_util::stored_query_correct_errors(builder).build().map_err(|err| {
   63         -
                ::aws_smithy_json::deserialize::error::DeserializeError::custom_source("Response was invalid", err)
   64         -
            })?))
   65         -
        }
   66         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   67         -
            "expected start object or null",
   68         -
        )),
   69         -
    }
   70         -
}
   71         -
   72         -
pub fn ser_stored_query(
   73         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
   74         -
    input: &crate::types::StoredQuery,
   75         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
   76         -
    if let Some(var_1) = &input.query_id {
   77         -
        object.key("QueryId").string(var_1.as_str());
   78         -
    }
   79         -
    if let Some(var_2) = &input.query_arn {
   80         -
        object.key("QueryArn").string(var_2.as_str());
   81         -
    }
   82         -
    {
   83         -
        object.key("QueryName").string(input.query_name.as_str());
   84         -
    }
   85         -
    if let Some(var_3) = &input.description {
   86         -
        object.key("Description").string(var_3.as_str());
   87         -
    }
   88         -
    if let Some(var_4) = &input.expression {
   89         -
        object.key("Expression").string(var_4.as_str());
   90         -
    }
   91         -
    Ok(())
   92         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_stored_query_metadata.rs

@@ -1,0 +63,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_stored_query_metadata<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::StoredQueryMetadata>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::StoredQueryMetadataBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "QueryId" => {
   19         -
                            builder = builder.set_query_id(
   20         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                                    .transpose()?,
   23         -
                            );
   24         -
                        }
   25         -
                        "QueryArn" => {
   26         -
                            builder = builder.set_query_arn(
   27         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   28         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   29         -
                                    .transpose()?,
   30         -
                            );
   31         -
                        }
   32         -
                        "QueryName" => {
   33         -
                            builder = builder.set_query_name(
   34         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   35         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   36         -
                                    .transpose()?,
   37         -
                            );
   38         -
                        }
   39         -
                        "Description" => {
   40         -
                            builder = builder.set_description(
   41         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   42         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   43         -
                                    .transpose()?,
   44         -
                            );
   45         -
                        }
   46         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   47         -
                    },
   48         -
                    other => {
   49         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   50         -
                            "expected object key or end object, found: {other:?}"
   51         -
                        )))
   52         -
                    }
   53         -
                }
   54         -
            }
   55         -
            Ok(Some(crate::serde_util::stored_query_metadata_correct_errors(builder).build().map_err(
   56         -
                |err| ::aws_smithy_json::deserialize::error::DeserializeError::custom_source("Response was invalid", err),
   57         -
            )?))
   58         -
        }
   59         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   60         -
            "expected start object or null",
   61         -
        )),
   62         -
    }
   63         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_stored_query_metadata_list.rs

@@ -1,0 +37,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_stored_query_metadata_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<::std::vec::Vec<crate::types::StoredQueryMetadata>>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   12         -
            let mut items = Vec::new();
   13         -
            loop {
   14         -
                match tokens.peek() {
   15         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   16         -
                        tokens.next().transpose().unwrap();
   17         -
                        break;
   18         -
                    }
   19         -
                    _ => {
   20         -
                        let value = crate::protocol_serde::shape_stored_query_metadata::de_stored_query_metadata(tokens, _value)?;
   21         -
                        if let Some(value) = value {
   22         -
                            items.push(value);
   23         -
                        } else {
   24         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   25         -
                                "dense list cannot contain null values",
   26         -
                            ));
   27         -
                        }
   28         -
                    }
   29         -
                }
   30         -
            }
   31         -
            Ok(Some(items))
   32         -
        }
   33         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   34         -
            "expected start array or null",
   35         -
        )),
   36         -
    }
   37         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_supplementary_configuration.rs

@@ -1,0 +48,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_supplementary_configuration<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<
    6         -
    Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
>
    9         -
where
   10         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   11         -
{
   12         -
    match tokens.next().transpose()? {
   13         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   14         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   15         -
            let mut map = ::std::collections::HashMap::new();
   16         -
            loop {
   17         -
                match tokens.next().transpose()? {
   18         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   19         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
   20         -
                        let key = key.to_unescaped().map(|u| u.into_owned())?;
   21         -
                        let value = ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   22         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   23         -
                            .transpose()?;
   24         -
                        match value {
   25         -
                            Some(value) => {
   26         -
                                map.insert(key, value);
   27         -
                            }
   28         -
                            None => {
   29         -
                                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   30         -
                                    "dense map cannot contain null values",
   31         -
                                ))
   32         -
                            }
   33         -
                        }
   34         -
                    }
   35         -
                    other => {
   36         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   37         -
                            "expected object key or end object, found: {other:?}"
   38         -
                        )))
   39         -
                    }
   40         -
                }
   41         -
            }
   42         -
            Ok(Some(map))
   43         -
        }
   44         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   45         -
            "expected start object or null",
   46         -
        )),
   47         -
    }
   48         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_tag.rs

@@ -1,0 +60,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_tag(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::Tag,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.key {
    7         -
        object.key("Key").string(var_1.as_str());
    8         -
    }
    9         -
    if let Some(var_2) = &input.value {
   10         -
        object.key("Value").string(var_2.as_str());
   11         -
    }
   12         -
    Ok(())
   13         -
}
   14         -
   15         -
pub(crate) fn de_tag<'a, I>(
   16         -
    tokens: &mut ::std::iter::Peekable<I>,
   17         -
    _value: &'a [u8],
   18         -
) -> ::std::result::Result<Option<crate::types::Tag>, ::aws_smithy_json::deserialize::error::DeserializeError>
   19         -
where
   20         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   21         -
{
   22         -
    match tokens.next().transpose()? {
   23         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   24         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   25         -
            #[allow(unused_mut)]
   26         -
            let mut builder = crate::types::builders::TagBuilder::default();
   27         -
            loop {
   28         -
                match tokens.next().transpose()? {
   29         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   30         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   31         -
                        "Key" => {
   32         -
                            builder = builder.set_key(
   33         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   34         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   35         -
                                    .transpose()?,
   36         -
                            );
   37         -
                        }
   38         -
                        "Value" => {
   39         -
                            builder = builder.set_value(
   40         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   41         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   42         -
                                    .transpose()?,
   43         -
                            );
   44         -
                        }
   45         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   46         -
                    },
   47         -
                    other => {
   48         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   49         -
                            "expected object key or end object, found: {other:?}"
   50         -
                        )))
   51         -
                    }
   52         -
                }
   53         -
            }
   54         -
            Ok(Some(builder.build()))
   55         -
        }
   56         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   57         -
            "expected start object or null",
   58         -
        )),
   59         -
    }
   60         -
}

tmp-codegen-diff/aws-sdk/sdk/config/src/protocol_serde/shape_tag_list.rs

@@ -1,0 +37,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_tag_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<::std::vec::Vec<crate::types::Tag>>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   12         -
            let mut items = Vec::new();
   13         -
            loop {
   14         -
                match tokens.peek() {
   15         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   16         -
                        tokens.next().transpose().unwrap();
   17         -
                        break;
   18         -
                    }
   19         -
                    _ => {
   20         -
                        let value = crate::protocol_serde::shape_tag::de_tag(tokens, _value)?;
   21         -
                        if let Some(value) = value {
   22         -
                            items.push(value);
   23         -
                        } else {
   24         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   25         -
                                "dense list cannot contain null values",
   26         -
                            ));
   27         -
                        }
   28         -
                    }
   29         -
                }
   30         -
            }
   31         -
            Ok(Some(items))
   32         -
        }
   33         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   34         -
            "expected start array or null",
   35         -
        )),
   36         -
    }
   37         -
}