pub fn ser_promote_read_replica_input_input_input(
input: &crate::operation::promote_read_replica::PromoteReadReplicaInput,
) -> ::std::result::Result<::aws_smithy_types::body::SdkBody, ::aws_smithy_types::error::operation::SerializationError> {
let mut out = String::new();
#[allow(unused_mut)]
let mut writer = ::aws_smithy_query::QueryWriter::new(&mut out, "PromoteReadReplica", "2014-10-31");
#[allow(unused_mut)]
let mut scope_1 = writer.prefix("DBInstanceIdentifier");
if let Some(var_2) = &input.db_instance_identifier {
scope_1.string(var_2);
}
#[allow(unused_mut)]
let mut scope_3 = writer.prefix("BackupRetentionPeriod");
if let Some(var_4) = &input.backup_retention_period {
scope_3.number(
#[allow(clippy::useless_conversion)]
::aws_smithy_types::Number::NegInt((*var_4).into()),
);
}
#[allow(unused_mut)]
let mut scope_5 = writer.prefix("PreferredBackupWindow");
if let Some(var_6) = &input.preferred_backup_window {
scope_5.string(var_6);
}
#[allow(unused_mut)]
let mut scope_7 = writer.prefix("TagSpecifications");
if let Some(var_8) = &input.tag_specifications {
let mut list_10 = scope_7.start_list(false, Some("item"));
for item_9 in var_8 {
#[allow(unused_mut)]
let mut entry_11 = list_10.entry();
crate::protocol_serde::shape_tag_specification::ser_tag_specification(entry_11, item_9)?;
}
list_10.finish();
}
writer.finish();
Ok(::aws_smithy_types::body::SdkBody::from(out))
}