aws-sdk-workspacesinstances 1.35.0

AWS SDK for Amazon Workspaces Instances
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
pub fn ser_create_volume_input_input(
    encoder: &mut ::aws_smithy_cbor::Encoder,
    #[allow(unused)] input: &crate::operation::create_volume::CreateVolumeInput,
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    encoder.begin_map();
    if let Some(var_1) = &input.availability_zone {
        encoder.str("AvailabilityZone").str(var_1.as_str());
    }
    if let Some(var_2) = &input.client_token {
        encoder.str("ClientToken").str(var_2.as_str());
    }
    if let Some(var_3) = &input.encrypted {
        encoder.str("Encrypted").boolean(*var_3);
    }
    if let Some(var_4) = &input.iops {
        encoder.str("Iops").integer(*var_4);
    }
    if let Some(var_5) = &input.kms_key_id {
        encoder.str("KmsKeyId").str(var_5.as_str());
    }
    if let Some(var_6) = &input.size_in_gb {
        encoder.str("SizeInGB").integer(*var_6);
    }
    if let Some(var_7) = &input.snapshot_id {
        encoder.str("SnapshotId").str(var_7.as_str());
    }
    if let Some(var_8) = &input.tag_specifications {
        encoder.str("TagSpecifications");
        encoder.array((*var_8).len());
        for item_9 in var_8 {
            {
                crate::protocol_serde::shape_tag_specification::ser_tag_specification(encoder, item_9)?;
            }
        }
    }
    if let Some(var_10) = &input.throughput {
        encoder.str("Throughput").integer(*var_10);
    }
    if let Some(var_11) = &input.volume_type {
        encoder.str("VolumeType").str(var_11.as_str());
    }
    encoder.end();
    Ok(())
}