#[non_exhaustive]pub struct ResourceDrift {
pub name: String,
pub terraform_info: Option<ResourceDriftTerraformInfo>,
pub property_drifts: Vec<PropertyDrift>,
/* private fields */
}Expand description
A resource drift represents a drift to a resource in the state file.
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.name: StringIdentifier. The name of the resource drift. Format: ‘projects/{project_id}/locations/{location}/previews/{preview}/resourceDrifts/{resource_drift}’.
terraform_info: Option<ResourceDriftTerraformInfo>Output only. Terraform info of the resource drift.
property_drifts: Vec<PropertyDrift>Output only. The property drifts of the resource drift.
Implementations§
Source§impl ResourceDrift
impl ResourceDrift
pub fn new() -> Self
Sourcepub fn set_terraform_info<T>(self, v: T) -> Selfwhere
T: Into<ResourceDriftTerraformInfo>,
pub fn set_terraform_info<T>(self, v: T) -> Selfwhere
T: Into<ResourceDriftTerraformInfo>,
Sets the value of terraform_info.
§Example
ⓘ
use google_cloud_config_v1::model::ResourceDriftTerraformInfo;
let x = ResourceDrift::new().set_terraform_info(ResourceDriftTerraformInfo::default()/* use setters */);Sourcepub fn set_or_clear_terraform_info<T>(self, v: Option<T>) -> Selfwhere
T: Into<ResourceDriftTerraformInfo>,
pub fn set_or_clear_terraform_info<T>(self, v: Option<T>) -> Selfwhere
T: Into<ResourceDriftTerraformInfo>,
Sets or clears the value of terraform_info.
§Example
ⓘ
use google_cloud_config_v1::model::ResourceDriftTerraformInfo;
let x = ResourceDrift::new().set_or_clear_terraform_info(Some(ResourceDriftTerraformInfo::default()/* use setters */));
let x = ResourceDrift::new().set_or_clear_terraform_info(None::<ResourceDriftTerraformInfo>);Sourcepub fn set_property_drifts<T, V>(self, v: T) -> Self
pub fn set_property_drifts<T, V>(self, v: T) -> Self
Sets the value of property_drifts.
§Example
ⓘ
use google_cloud_config_v1::model::PropertyDrift;
let x = ResourceDrift::new()
.set_property_drifts([
PropertyDrift::default()/* use setters */,
PropertyDrift::default()/* use (different) setters */,
]);Trait Implementations§
Source§impl Clone for ResourceDrift
impl Clone for ResourceDrift
Source§fn clone(&self) -> ResourceDrift
fn clone(&self) -> ResourceDrift
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 Debug for ResourceDrift
impl Debug for ResourceDrift
Source§impl Default for ResourceDrift
impl Default for ResourceDrift
Source§fn default() -> ResourceDrift
fn default() -> ResourceDrift
Returns the “default value” for a type. Read more
Source§impl Message for ResourceDrift
impl Message for ResourceDrift
Source§impl PartialEq for ResourceDrift
impl PartialEq for ResourceDrift
impl StructuralPartialEq for ResourceDrift
Auto Trait Implementations§
impl Freeze for ResourceDrift
impl RefUnwindSafe for ResourceDrift
impl Send for ResourceDrift
impl Sync for ResourceDrift
impl Unpin for ResourceDrift
impl UnsafeUnpin for ResourceDrift
impl UnwindSafe for ResourceDrift
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