aws-sdk-ses 1.99.0

AWS SDK for Amazon Simple Email Service
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(unused_mut)]
pub fn ser_delivery_options(
    mut writer: ::aws_smithy_query::QueryValueWriter,
    input: &crate::types::DeliveryOptions,
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    #[allow(unused_mut)]
    let mut scope_1 = writer.prefix("TlsPolicy");
    if let Some(var_2) = &input.tls_policy {
        scope_1.string(var_2.as_str());
    }
    Ok(())
}

#[allow(clippy::needless_question_mark)]
pub fn de_delivery_options(
    decoder: &mut ::aws_smithy_xml::decode::ScopedDecoder,
) -> ::std::result::Result<crate::types::DeliveryOptions, ::aws_smithy_xml::decode::XmlDecodeError> {
    #[allow(unused_mut)]
    let mut builder = crate::types::DeliveryOptions::builder();
    while let Some(mut tag) = decoder.next_tag() {
        match tag.start_el() {
            s if s.matches("TlsPolicy") /* TlsPolicy com.amazonaws.ses#DeliveryOptions$TlsPolicy */ =>  {
                let var_3 =
                    Some(
                        Result::<crate::types::TlsPolicy, ::aws_smithy_xml::decode::XmlDecodeError>::Ok(
                            crate::types::TlsPolicy::from(
                                ::aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
                            )
                        )
                        ?
                    )
                ;
                builder = builder.set_tls_policy(var_3);
            }
            ,
            _ => {}
        }
    }
    Ok(builder.build())
}