#[non_exhaustive]pub struct AllocationResourceStatusSpecificSKUAllocation {
pub source_instance_template_id: Option<String>,
pub utilizations: HashMap<String, i64>,
/* private fields */
}Available on crate features
region-commitments or reservations only.Expand description
Contains Properties set for the reservation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.source_instance_template_id: Option<String>ID of the instance template used to populate reservation properties.
utilizations: HashMap<String, i64>Per service utilization breakdown. The Key is the Google Cloud managed service name.
Implementations§
Source§impl AllocationResourceStatusSpecificSKUAllocation
impl AllocationResourceStatusSpecificSKUAllocation
pub fn new() -> Self
Sourcepub fn set_source_instance_template_id<T>(self, v: T) -> Self
pub fn set_source_instance_template_id<T>(self, v: T) -> Self
Sets the value of source_instance_template_id.
§Example
ⓘ
let x = AllocationResourceStatusSpecificSKUAllocation::new().set_source_instance_template_id("example");Sourcepub fn set_or_clear_source_instance_template_id<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_source_instance_template_id<T>(self, v: Option<T>) -> Self
Sets or clears the value of source_instance_template_id.
§Example
ⓘ
let x = AllocationResourceStatusSpecificSKUAllocation::new().set_or_clear_source_instance_template_id(Some("example"));
let x = AllocationResourceStatusSpecificSKUAllocation::new().set_or_clear_source_instance_template_id(None::<String>);Sourcepub fn set_utilizations<T, K, V>(self, v: T) -> Self
pub fn set_utilizations<T, K, V>(self, v: T) -> Self
Sets the value of utilizations.
§Example
ⓘ
let x = AllocationResourceStatusSpecificSKUAllocation::new().set_utilizations([
("key0", 123),
("key1", 456),
]);Trait Implementations§
Source§impl Clone for AllocationResourceStatusSpecificSKUAllocation
impl Clone for AllocationResourceStatusSpecificSKUAllocation
Source§fn clone(&self) -> AllocationResourceStatusSpecificSKUAllocation
fn clone(&self) -> AllocationResourceStatusSpecificSKUAllocation
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for AllocationResourceStatusSpecificSKUAllocation
impl Default for AllocationResourceStatusSpecificSKUAllocation
Source§fn default() -> AllocationResourceStatusSpecificSKUAllocation
fn default() -> AllocationResourceStatusSpecificSKUAllocation
Returns the “default value” for a type. Read more
Source§impl PartialEq for AllocationResourceStatusSpecificSKUAllocation
impl PartialEq for AllocationResourceStatusSpecificSKUAllocation
Source§fn eq(&self, other: &AllocationResourceStatusSpecificSKUAllocation) -> bool
fn eq(&self, other: &AllocationResourceStatusSpecificSKUAllocation) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for AllocationResourceStatusSpecificSKUAllocation
Auto Trait Implementations§
impl Freeze for AllocationResourceStatusSpecificSKUAllocation
impl RefUnwindSafe for AllocationResourceStatusSpecificSKUAllocation
impl Send for AllocationResourceStatusSpecificSKUAllocation
impl Sync for AllocationResourceStatusSpecificSKUAllocation
impl Unpin for AllocationResourceStatusSpecificSKUAllocation
impl UnwindSafe for AllocationResourceStatusSpecificSKUAllocation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more