1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>The minimum and maximum amount of memory per vCPU, in GiB.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct MemoryGiBPerVCpuRequest {
/// <p>The minimum amount of memory per vCPU, in GiB. To specify no minimum limit, omit this parameter.</p>
pub min: ::std::option::Option<f64>,
/// <p>The maximum amount of memory per vCPU, in GiB. To specify no maximum limit, omit this parameter.</p>
pub max: ::std::option::Option<f64>,
}
impl MemoryGiBPerVCpuRequest {
/// <p>The minimum amount of memory per vCPU, in GiB. To specify no minimum limit, omit this parameter.</p>
pub fn min(&self) -> ::std::option::Option<f64> {
self.min
}
/// <p>The maximum amount of memory per vCPU, in GiB. To specify no maximum limit, omit this parameter.</p>
pub fn max(&self) -> ::std::option::Option<f64> {
self.max
}
}
impl MemoryGiBPerVCpuRequest {
/// Creates a new builder-style object to manufacture [`MemoryGiBPerVCpuRequest`](crate::types::MemoryGiBPerVCpuRequest).
pub fn builder() -> crate::types::builders::MemoryGiBPerVCpuRequestBuilder {
crate::types::builders::MemoryGiBPerVCpuRequestBuilder::default()
}
}
/// A builder for [`MemoryGiBPerVCpuRequest`](crate::types::MemoryGiBPerVCpuRequest).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct MemoryGiBPerVCpuRequestBuilder {
pub(crate) min: ::std::option::Option<f64>,
pub(crate) max: ::std::option::Option<f64>,
}
impl MemoryGiBPerVCpuRequestBuilder {
/// <p>The minimum amount of memory per vCPU, in GiB. To specify no minimum limit, omit this parameter.</p>
pub fn min(mut self, input: f64) -> Self {
self.min = ::std::option::Option::Some(input);
self
}
/// <p>The minimum amount of memory per vCPU, in GiB. To specify no minimum limit, omit this parameter.</p>
pub fn set_min(mut self, input: ::std::option::Option<f64>) -> Self {
self.min = input;
self
}
/// <p>The minimum amount of memory per vCPU, in GiB. To specify no minimum limit, omit this parameter.</p>
pub fn get_min(&self) -> &::std::option::Option<f64> {
&self.min
}
/// <p>The maximum amount of memory per vCPU, in GiB. To specify no maximum limit, omit this parameter.</p>
pub fn max(mut self, input: f64) -> Self {
self.max = ::std::option::Option::Some(input);
self
}
/// <p>The maximum amount of memory per vCPU, in GiB. To specify no maximum limit, omit this parameter.</p>
pub fn set_max(mut self, input: ::std::option::Option<f64>) -> Self {
self.max = input;
self
}
/// <p>The maximum amount of memory per vCPU, in GiB. To specify no maximum limit, omit this parameter.</p>
pub fn get_max(&self) -> &::std::option::Option<f64> {
&self.max
}
/// Consumes the builder and constructs a [`MemoryGiBPerVCpuRequest`](crate::types::MemoryGiBPerVCpuRequest).
pub fn build(self) -> crate::types::MemoryGiBPerVCpuRequest {
crate::types::MemoryGiBPerVCpuRequest {
min: self.min,
max: self.max,
}
}
}