pub fn serialize_structure_crate_input_associate_vpc_with_hosted_zone_input(
input: &crate::input::AssociateVpcWithHostedZoneInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_1) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_1.as_ref());
}
if let Some(var_2) = &input.vpc {
let inner_writer = scope.start_el("VPC");
crate::xml_ser::serialize_structure_crate_model_vpc(var_2, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_change_resource_record_sets_input(
input: &crate::input::ChangeResourceRecordSetsInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_3) = &input.change_batch {
let inner_writer = scope.start_el("ChangeBatch");
crate::xml_ser::serialize_structure_crate_model_change_batch(var_3, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_change_tags_for_resource_input(
input: &crate::input::ChangeTagsForResourceInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_4) = &input.add_tags {
let mut inner_writer = scope.start_el("AddTags").finish();
for list_item_5 in var_4 {
{
let inner_writer = inner_writer.start_el("Tag");
crate::xml_ser::serialize_structure_crate_model_tag(list_item_5, inner_writer)?
}
}
}
if let Some(var_6) = &input.remove_tag_keys {
let mut inner_writer = scope.start_el("RemoveTagKeys").finish();
for list_item_7 in var_6 {
{
let mut inner_writer = inner_writer.start_el("Key").finish();
inner_writer.data(list_item_7.as_ref());
}
}
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_health_check_input(
input: &crate::input::CreateHealthCheckInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_8) = &input.caller_reference {
let mut inner_writer = scope.start_el("CallerReference").finish();
inner_writer.data(var_8.as_ref());
}
if let Some(var_9) = &input.health_check_config {
let inner_writer = scope.start_el("HealthCheckConfig");
crate::xml_ser::serialize_structure_crate_model_health_check_config(var_9, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_hosted_zone_input(
input: &crate::input::CreateHostedZoneInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_10) = &input.caller_reference {
let mut inner_writer = scope.start_el("CallerReference").finish();
inner_writer.data(var_10.as_ref());
}
if let Some(var_11) = &input.delegation_set_id {
let mut inner_writer = scope.start_el("DelegationSetId").finish();
inner_writer.data(var_11.as_ref());
}
if let Some(var_12) = &input.hosted_zone_config {
let inner_writer = scope.start_el("HostedZoneConfig");
crate::xml_ser::serialize_structure_crate_model_hosted_zone_config(var_12, inner_writer)?
}
if let Some(var_13) = &input.name {
let mut inner_writer = scope.start_el("Name").finish();
inner_writer.data(var_13.as_ref());
}
if let Some(var_14) = &input.vpc {
let inner_writer = scope.start_el("VPC");
crate::xml_ser::serialize_structure_crate_model_vpc(var_14, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_key_signing_key_input(
input: &crate::input::CreateKeySigningKeyInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_15) = &input.caller_reference {
let mut inner_writer = scope.start_el("CallerReference").finish();
inner_writer.data(var_15.as_ref());
}
if let Some(var_16) = &input.hosted_zone_id {
let mut inner_writer = scope.start_el("HostedZoneId").finish();
inner_writer.data(var_16.as_ref());
}
if let Some(var_17) = &input.key_management_service_arn {
let mut inner_writer = scope.start_el("KeyManagementServiceArn").finish();
inner_writer.data(var_17.as_ref());
}
if let Some(var_18) = &input.name {
let mut inner_writer = scope.start_el("Name").finish();
inner_writer.data(var_18.as_ref());
}
if let Some(var_19) = &input.status {
let mut inner_writer = scope.start_el("Status").finish();
inner_writer.data(var_19.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_query_logging_config_input(
input: &crate::input::CreateQueryLoggingConfigInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_20) = &input.cloud_watch_logs_log_group_arn {
let mut inner_writer = scope.start_el("CloudWatchLogsLogGroupArn").finish();
inner_writer.data(var_20.as_ref());
}
if let Some(var_21) = &input.hosted_zone_id {
let mut inner_writer = scope.start_el("HostedZoneId").finish();
inner_writer.data(var_21.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_reusable_delegation_set_input(
input: &crate::input::CreateReusableDelegationSetInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_22) = &input.caller_reference {
let mut inner_writer = scope.start_el("CallerReference").finish();
inner_writer.data(var_22.as_ref());
}
if let Some(var_23) = &input.hosted_zone_id {
let mut inner_writer = scope.start_el("HostedZoneId").finish();
inner_writer.data(var_23.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_traffic_policy_input(
input: &crate::input::CreateTrafficPolicyInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_24) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_24.as_ref());
}
if let Some(var_25) = &input.document {
let mut inner_writer = scope.start_el("Document").finish();
inner_writer.data(var_25.as_ref());
}
if let Some(var_26) = &input.name {
let mut inner_writer = scope.start_el("Name").finish();
inner_writer.data(var_26.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_traffic_policy_instance_input(
input: &crate::input::CreateTrafficPolicyInstanceInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_27) = &input.hosted_zone_id {
let mut inner_writer = scope.start_el("HostedZoneId").finish();
inner_writer.data(var_27.as_ref());
}
if let Some(var_28) = &input.name {
let mut inner_writer = scope.start_el("Name").finish();
inner_writer.data(var_28.as_ref());
}
if let Some(var_29) = &input.ttl {
let mut inner_writer = scope.start_el("TTL").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_29).encode());
}
if let Some(var_30) = &input.traffic_policy_id {
let mut inner_writer = scope.start_el("TrafficPolicyId").finish();
inner_writer.data(var_30.as_ref());
}
if let Some(var_31) = &input.traffic_policy_version {
let mut inner_writer = scope.start_el("TrafficPolicyVersion").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_31).encode());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_traffic_policy_version_input(
input: &crate::input::CreateTrafficPolicyVersionInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_32) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_32.as_ref());
}
if let Some(var_33) = &input.document {
let mut inner_writer = scope.start_el("Document").finish();
inner_writer.data(var_33.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_create_vpc_association_authorization_input(
input: &crate::input::CreateVpcAssociationAuthorizationInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_34) = &input.vpc {
let inner_writer = scope.start_el("VPC");
crate::xml_ser::serialize_structure_crate_model_vpc(var_34, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_delete_vpc_association_authorization_input(
input: &crate::input::DeleteVpcAssociationAuthorizationInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_35) = &input.vpc {
let inner_writer = scope.start_el("VPC");
crate::xml_ser::serialize_structure_crate_model_vpc(var_35, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_disassociate_vpc_from_hosted_zone_input(
input: &crate::input::DisassociateVpcFromHostedZoneInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_36) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_36.as_ref());
}
if let Some(var_37) = &input.vpc {
let inner_writer = scope.start_el("VPC");
crate::xml_ser::serialize_structure_crate_model_vpc(var_37, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_list_tags_for_resources_input(
input: &crate::input::ListTagsForResourcesInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_38) = &input.resource_ids {
let mut inner_writer = scope.start_el("ResourceIds").finish();
for list_item_39 in var_38 {
{
let mut inner_writer = inner_writer.start_el("ResourceId").finish();
inner_writer.data(list_item_39.as_ref());
}
}
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_update_health_check_input(
input: &crate::input::UpdateHealthCheckInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_40) = &input.alarm_identifier {
let inner_writer = scope.start_el("AlarmIdentifier");
crate::xml_ser::serialize_structure_crate_model_alarm_identifier(var_40, inner_writer)?
}
if let Some(var_41) = &input.child_health_checks {
let mut inner_writer = scope.start_el("ChildHealthChecks").finish();
for list_item_42 in var_41 {
{
let mut inner_writer = inner_writer.start_el("ChildHealthCheck").finish();
inner_writer.data(list_item_42.as_ref());
}
}
}
if let Some(var_43) = &input.disabled {
let mut inner_writer = scope.start_el("Disabled").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_43).encode());
}
if let Some(var_44) = &input.enable_sni {
let mut inner_writer = scope.start_el("EnableSNI").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_44).encode());
}
if let Some(var_45) = &input.failure_threshold {
let mut inner_writer = scope.start_el("FailureThreshold").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_45).encode());
}
if let Some(var_46) = &input.fully_qualified_domain_name {
let mut inner_writer = scope.start_el("FullyQualifiedDomainName").finish();
inner_writer.data(var_46.as_ref());
}
if let Some(var_47) = &input.health_check_version {
let mut inner_writer = scope.start_el("HealthCheckVersion").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_47).encode());
}
if let Some(var_48) = &input.health_threshold {
let mut inner_writer = scope.start_el("HealthThreshold").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_48).encode());
}
if let Some(var_49) = &input.ip_address {
let mut inner_writer = scope.start_el("IPAddress").finish();
inner_writer.data(var_49.as_ref());
}
if let Some(var_50) = &input.insufficient_data_health_status {
let mut inner_writer = scope.start_el("InsufficientDataHealthStatus").finish();
inner_writer.data(var_50.as_str());
}
if let Some(var_51) = &input.inverted {
let mut inner_writer = scope.start_el("Inverted").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_51).encode());
}
if let Some(var_52) = &input.port {
let mut inner_writer = scope.start_el("Port").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_52).encode());
}
if let Some(var_53) = &input.regions {
let mut inner_writer = scope.start_el("Regions").finish();
for list_item_54 in var_53 {
{
let mut inner_writer = inner_writer.start_el("Region").finish();
inner_writer.data(list_item_54.as_str());
}
}
}
if let Some(var_55) = &input.reset_elements {
let mut inner_writer = scope.start_el("ResetElements").finish();
for list_item_56 in var_55 {
{
let mut inner_writer = inner_writer.start_el("ResettableElementName").finish();
inner_writer.data(list_item_56.as_str());
}
}
}
if let Some(var_57) = &input.resource_path {
let mut inner_writer = scope.start_el("ResourcePath").finish();
inner_writer.data(var_57.as_ref());
}
if let Some(var_58) = &input.search_string {
let mut inner_writer = scope.start_el("SearchString").finish();
inner_writer.data(var_58.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_update_hosted_zone_comment_input(
input: &crate::input::UpdateHostedZoneCommentInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_59) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_59.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_update_traffic_policy_comment_input(
input: &crate::input::UpdateTrafficPolicyCommentInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_60) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_60.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_input_update_traffic_policy_instance_input(
input: &crate::input::UpdateTrafficPolicyInstanceInput,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_61) = &input.ttl {
let mut inner_writer = scope.start_el("TTL").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_61).encode());
}
if let Some(var_62) = &input.traffic_policy_id {
let mut inner_writer = scope.start_el("TrafficPolicyId").finish();
inner_writer.data(var_62.as_ref());
}
if let Some(var_63) = &input.traffic_policy_version {
let mut inner_writer = scope.start_el("TrafficPolicyVersion").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_63).encode());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_vpc(
input: &crate::model::Vpc,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_64) = &input.vpc_region {
let mut inner_writer = scope.start_el("VPCRegion").finish();
inner_writer.data(var_64.as_str());
}
if let Some(var_65) = &input.vpc_id {
let mut inner_writer = scope.start_el("VPCId").finish();
inner_writer.data(var_65.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_change_batch(
input: &crate::model::ChangeBatch,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_66) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_66.as_ref());
}
if let Some(var_67) = &input.changes {
let mut inner_writer = scope.start_el("Changes").finish();
for list_item_68 in var_67 {
{
let inner_writer = inner_writer.start_el("Change");
crate::xml_ser::serialize_structure_crate_model_change(list_item_68, inner_writer)?
}
}
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_tag(
input: &crate::model::Tag,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_69) = &input.key {
let mut inner_writer = scope.start_el("Key").finish();
inner_writer.data(var_69.as_ref());
}
if let Some(var_70) = &input.value {
let mut inner_writer = scope.start_el("Value").finish();
inner_writer.data(var_70.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_health_check_config(
input: &crate::model::HealthCheckConfig,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_71) = &input.ip_address {
let mut inner_writer = scope.start_el("IPAddress").finish();
inner_writer.data(var_71.as_ref());
}
if let Some(var_72) = &input.port {
let mut inner_writer = scope.start_el("Port").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_72).encode());
}
if let Some(var_73) = &input.r#type {
let mut inner_writer = scope.start_el("Type").finish();
inner_writer.data(var_73.as_str());
}
if let Some(var_74) = &input.resource_path {
let mut inner_writer = scope.start_el("ResourcePath").finish();
inner_writer.data(var_74.as_ref());
}
if let Some(var_75) = &input.fully_qualified_domain_name {
let mut inner_writer = scope.start_el("FullyQualifiedDomainName").finish();
inner_writer.data(var_75.as_ref());
}
if let Some(var_76) = &input.search_string {
let mut inner_writer = scope.start_el("SearchString").finish();
inner_writer.data(var_76.as_ref());
}
if let Some(var_77) = &input.request_interval {
let mut inner_writer = scope.start_el("RequestInterval").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_77).encode());
}
if let Some(var_78) = &input.failure_threshold {
let mut inner_writer = scope.start_el("FailureThreshold").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_78).encode());
}
if let Some(var_79) = &input.measure_latency {
let mut inner_writer = scope.start_el("MeasureLatency").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_79).encode());
}
if let Some(var_80) = &input.inverted {
let mut inner_writer = scope.start_el("Inverted").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_80).encode());
}
if let Some(var_81) = &input.disabled {
let mut inner_writer = scope.start_el("Disabled").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_81).encode());
}
if let Some(var_82) = &input.health_threshold {
let mut inner_writer = scope.start_el("HealthThreshold").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_82).encode());
}
if let Some(var_83) = &input.child_health_checks {
let mut inner_writer = scope.start_el("ChildHealthChecks").finish();
for list_item_84 in var_83 {
{
let mut inner_writer = inner_writer.start_el("ChildHealthCheck").finish();
inner_writer.data(list_item_84.as_ref());
}
}
}
if let Some(var_85) = &input.enable_sni {
let mut inner_writer = scope.start_el("EnableSNI").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_85).encode());
}
if let Some(var_86) = &input.regions {
let mut inner_writer = scope.start_el("Regions").finish();
for list_item_87 in var_86 {
{
let mut inner_writer = inner_writer.start_el("Region").finish();
inner_writer.data(list_item_87.as_str());
}
}
}
if let Some(var_88) = &input.alarm_identifier {
let inner_writer = scope.start_el("AlarmIdentifier");
crate::xml_ser::serialize_structure_crate_model_alarm_identifier(var_88, inner_writer)?
}
if let Some(var_89) = &input.insufficient_data_health_status {
let mut inner_writer = scope.start_el("InsufficientDataHealthStatus").finish();
inner_writer.data(var_89.as_str());
}
if let Some(var_90) = &input.routing_control_arn {
let mut inner_writer = scope.start_el("RoutingControlArn").finish();
inner_writer.data(var_90.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_hosted_zone_config(
input: &crate::model::HostedZoneConfig,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_91) = &input.comment {
let mut inner_writer = scope.start_el("Comment").finish();
inner_writer.data(var_91.as_ref());
}
if input.private_zone {
let mut inner_writer = scope.start_el("PrivateZone").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(input.private_zone).encode());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_alarm_identifier(
input: &crate::model::AlarmIdentifier,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_92) = &input.region {
let mut inner_writer = scope.start_el("Region").finish();
inner_writer.data(var_92.as_str());
}
if let Some(var_93) = &input.name {
let mut inner_writer = scope.start_el("Name").finish();
inner_writer.data(var_93.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_change(
input: &crate::model::Change,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_94) = &input.action {
let mut inner_writer = scope.start_el("Action").finish();
inner_writer.data(var_94.as_str());
}
if let Some(var_95) = &input.resource_record_set {
let inner_writer = scope.start_el("ResourceRecordSet");
crate::xml_ser::serialize_structure_crate_model_resource_record_set(var_95, inner_writer)?
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_resource_record_set(
input: &crate::model::ResourceRecordSet,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_96) = &input.name {
let mut inner_writer = scope.start_el("Name").finish();
inner_writer.data(var_96.as_ref());
}
if let Some(var_97) = &input.r#type {
let mut inner_writer = scope.start_el("Type").finish();
inner_writer.data(var_97.as_str());
}
if let Some(var_98) = &input.set_identifier {
let mut inner_writer = scope.start_el("SetIdentifier").finish();
inner_writer.data(var_98.as_ref());
}
if let Some(var_99) = &input.weight {
let mut inner_writer = scope.start_el("Weight").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_99).encode());
}
if let Some(var_100) = &input.region {
let mut inner_writer = scope.start_el("Region").finish();
inner_writer.data(var_100.as_str());
}
if let Some(var_101) = &input.geo_location {
let inner_writer = scope.start_el("GeoLocation");
crate::xml_ser::serialize_structure_crate_model_geo_location(var_101, inner_writer)?
}
if let Some(var_102) = &input.failover {
let mut inner_writer = scope.start_el("Failover").finish();
inner_writer.data(var_102.as_str());
}
if let Some(var_103) = &input.multi_value_answer {
let mut inner_writer = scope.start_el("MultiValueAnswer").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_103).encode());
}
if let Some(var_104) = &input.ttl {
let mut inner_writer = scope.start_el("TTL").finish();
inner_writer.data(aws_smithy_types::primitive::Encoder::from(*var_104).encode());
}
if let Some(var_105) = &input.resource_records {
let mut inner_writer = scope.start_el("ResourceRecords").finish();
for list_item_106 in var_105 {
{
let inner_writer = inner_writer.start_el("ResourceRecord");
crate::xml_ser::serialize_structure_crate_model_resource_record(
list_item_106,
inner_writer,
)?
}
}
}
if let Some(var_107) = &input.alias_target {
let inner_writer = scope.start_el("AliasTarget");
crate::xml_ser::serialize_structure_crate_model_alias_target(var_107, inner_writer)?
}
if let Some(var_108) = &input.health_check_id {
let mut inner_writer = scope.start_el("HealthCheckId").finish();
inner_writer.data(var_108.as_ref());
}
if let Some(var_109) = &input.traffic_policy_instance_id {
let mut inner_writer = scope.start_el("TrafficPolicyInstanceId").finish();
inner_writer.data(var_109.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_geo_location(
input: &crate::model::GeoLocation,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_110) = &input.continent_code {
let mut inner_writer = scope.start_el("ContinentCode").finish();
inner_writer.data(var_110.as_ref());
}
if let Some(var_111) = &input.country_code {
let mut inner_writer = scope.start_el("CountryCode").finish();
inner_writer.data(var_111.as_ref());
}
if let Some(var_112) = &input.subdivision_code {
let mut inner_writer = scope.start_el("SubdivisionCode").finish();
inner_writer.data(var_112.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_resource_record(
input: &crate::model::ResourceRecord,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_113) = &input.value {
let mut inner_writer = scope.start_el("Value").finish();
inner_writer.data(var_113.as_ref());
}
scope.finish();
Ok(())
}
pub fn serialize_structure_crate_model_alias_target(
input: &crate::model::AliasTarget,
writer: aws_smithy_xml::encode::ElWriter,
) -> Result<(), aws_smithy_http::operation::SerializationError> {
#[allow(unused_mut)]
let mut scope = writer.finish();
if let Some(var_114) = &input.hosted_zone_id {
let mut inner_writer = scope.start_el("HostedZoneId").finish();
inner_writer.data(var_114.as_ref());
}
if let Some(var_115) = &input.dns_name {
let mut inner_writer = scope.start_el("DNSName").finish();
inner_writer.data(var_115.as_ref());
}
{
let mut inner_writer = scope.start_el("EvaluateTargetHealth").finish();
inner_writer.data(
aws_smithy_types::primitive::Encoder::from(input.evaluate_target_health).encode(),
);
}
scope.finish();
Ok(())
}