aws-sdk-workspacesinstances 1.46.0

AWS SDK for Amazon Workspaces Instances
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Contains the target configuration of the volume after the modification, including the size, volume type, IOPS, and throughput where applicable.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ModifyVolumeOutput {
    /// <p>Specifies the identifier of the modified volume.</p>
    pub volume_id: ::std::option::Option<::std::string::String>,
    /// <p>Specifies the target size of the volume, in GiB.</p>
    pub target_size: ::std::option::Option<i32>,
    /// <p>Specifies the target Amazon EBS volume type.</p>
    pub target_volume_type: ::std::option::Option<crate::types::VolumeTypeEnum>,
    /// <p>Specifies the target IOPS rate of the volume.</p>
    pub target_iops: ::std::option::Option<i32>,
    /// <p>Specifies the target throughput of the volume, in MiB/s.</p>
    pub target_throughput: ::std::option::Option<i32>,
    _request_id: Option<String>,
}
impl ModifyVolumeOutput {
    /// <p>Specifies the identifier of the modified volume.</p>
    pub fn volume_id(&self) -> ::std::option::Option<&str> {
        self.volume_id.as_deref()
    }
    /// <p>Specifies the target size of the volume, in GiB.</p>
    pub fn target_size(&self) -> ::std::option::Option<i32> {
        self.target_size
    }
    /// <p>Specifies the target Amazon EBS volume type.</p>
    pub fn target_volume_type(&self) -> ::std::option::Option<&crate::types::VolumeTypeEnum> {
        self.target_volume_type.as_ref()
    }
    /// <p>Specifies the target IOPS rate of the volume.</p>
    pub fn target_iops(&self) -> ::std::option::Option<i32> {
        self.target_iops
    }
    /// <p>Specifies the target throughput of the volume, in MiB/s.</p>
    pub fn target_throughput(&self) -> ::std::option::Option<i32> {
        self.target_throughput
    }
}
impl ::aws_types::request_id::RequestId for ModifyVolumeOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl ModifyVolumeOutput {
    /// Creates a new builder-style object to manufacture [`ModifyVolumeOutput`](crate::operation::modify_volume::ModifyVolumeOutput).
    pub fn builder() -> crate::operation::modify_volume::builders::ModifyVolumeOutputBuilder {
        crate::operation::modify_volume::builders::ModifyVolumeOutputBuilder::default()
    }
}

/// A builder for [`ModifyVolumeOutput`](crate::operation::modify_volume::ModifyVolumeOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ModifyVolumeOutputBuilder {
    pub(crate) volume_id: ::std::option::Option<::std::string::String>,
    pub(crate) target_size: ::std::option::Option<i32>,
    pub(crate) target_volume_type: ::std::option::Option<crate::types::VolumeTypeEnum>,
    pub(crate) target_iops: ::std::option::Option<i32>,
    pub(crate) target_throughput: ::std::option::Option<i32>,
    _request_id: Option<String>,
}
impl ModifyVolumeOutputBuilder {
    /// <p>Specifies the identifier of the modified volume.</p>
    pub fn volume_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.volume_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>Specifies the identifier of the modified volume.</p>
    pub fn set_volume_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.volume_id = input;
        self
    }
    /// <p>Specifies the identifier of the modified volume.</p>
    pub fn get_volume_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.volume_id
    }
    /// <p>Specifies the target size of the volume, in GiB.</p>
    pub fn target_size(mut self, input: i32) -> Self {
        self.target_size = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies the target size of the volume, in GiB.</p>
    pub fn set_target_size(mut self, input: ::std::option::Option<i32>) -> Self {
        self.target_size = input;
        self
    }
    /// <p>Specifies the target size of the volume, in GiB.</p>
    pub fn get_target_size(&self) -> &::std::option::Option<i32> {
        &self.target_size
    }
    /// <p>Specifies the target Amazon EBS volume type.</p>
    pub fn target_volume_type(mut self, input: crate::types::VolumeTypeEnum) -> Self {
        self.target_volume_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies the target Amazon EBS volume type.</p>
    pub fn set_target_volume_type(mut self, input: ::std::option::Option<crate::types::VolumeTypeEnum>) -> Self {
        self.target_volume_type = input;
        self
    }
    /// <p>Specifies the target Amazon EBS volume type.</p>
    pub fn get_target_volume_type(&self) -> &::std::option::Option<crate::types::VolumeTypeEnum> {
        &self.target_volume_type
    }
    /// <p>Specifies the target IOPS rate of the volume.</p>
    pub fn target_iops(mut self, input: i32) -> Self {
        self.target_iops = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies the target IOPS rate of the volume.</p>
    pub fn set_target_iops(mut self, input: ::std::option::Option<i32>) -> Self {
        self.target_iops = input;
        self
    }
    /// <p>Specifies the target IOPS rate of the volume.</p>
    pub fn get_target_iops(&self) -> &::std::option::Option<i32> {
        &self.target_iops
    }
    /// <p>Specifies the target throughput of the volume, in MiB/s.</p>
    pub fn target_throughput(mut self, input: i32) -> Self {
        self.target_throughput = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies the target throughput of the volume, in MiB/s.</p>
    pub fn set_target_throughput(mut self, input: ::std::option::Option<i32>) -> Self {
        self.target_throughput = input;
        self
    }
    /// <p>Specifies the target throughput of the volume, in MiB/s.</p>
    pub fn get_target_throughput(&self) -> &::std::option::Option<i32> {
        &self.target_throughput
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`ModifyVolumeOutput`](crate::operation::modify_volume::ModifyVolumeOutput).
    pub fn build(self) -> crate::operation::modify_volume::ModifyVolumeOutput {
        crate::operation::modify_volume::ModifyVolumeOutput {
            volume_id: self.volume_id,
            target_size: self.target_size,
            target_volume_type: self.target_volume_type,
            target_iops: self.target_iops,
            target_throughput: self.target_throughput,
            _request_id: self._request_id,
        }
    }
}