#[non_exhaustive]pub struct DisksMigrationVmTargetDefaults {Show 16 fields
pub vm_name: String,
pub machine_type_series: String,
pub machine_type: String,
pub network_tags: Vec<String>,
pub network_interfaces: Vec<NetworkInterface>,
pub service_account: String,
pub compute_scheduling: Option<ComputeScheduling>,
pub secure_boot: bool,
pub enable_vtpm: bool,
pub enable_integrity_monitoring: bool,
pub metadata: HashMap<String, String>,
pub additional_licenses: Vec<String>,
pub hostname: String,
pub labels: HashMap<String, String>,
pub boot_disk_defaults: Option<BootDiskDefaults>,
pub encryption: Option<Encryption>,
/* private fields */
}Expand description
Details for creation of a VM that migrated data disks will be attached to.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.vm_name: StringRequired. The name of the VM to create.
machine_type_series: StringOptional. The machine type series to create the VM with. For presentation only.
machine_type: StringRequired. The machine type to create the VM with.
Optional. A list of network tags to associate with the VM.
network_interfaces: Vec<NetworkInterface>Optional. NICs to attach to the VM.
service_account: StringOptional. The service account to associate the VM with.
compute_scheduling: Option<ComputeScheduling>Optional. Compute instance scheduling information (if empty default is used).
secure_boot: boolOptional. Defines whether the instance has Secure Boot enabled. This can be set to true only if the VM boot option is EFI.
enable_vtpm: boolOptional. Defines whether the instance has vTPM enabled.
enable_integrity_monitoring: boolOptional. Defines whether the instance has integrity monitoring enabled.
metadata: HashMap<String, String>Optional. The metadata key/value pairs to assign to the VM.
additional_licenses: Vec<String>Optional. Additional licenses to assign to the VM.
hostname: StringOptional. The hostname to assign to the VM.
labels: HashMap<String, String>Optional. A map of labels to associate with the VM.
boot_disk_defaults: Option<BootDiskDefaults>Optional. Details of the boot disk of the VM.
encryption: Option<Encryption>Optional. The encryption to apply to the VM.
Implementations§
Source§impl DisksMigrationVmTargetDefaults
impl DisksMigrationVmTargetDefaults
Sourcepub fn set_vm_name<T: Into<String>>(self, v: T) -> Self
pub fn set_vm_name<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_machine_type_series<T: Into<String>>(self, v: T) -> Self
pub fn set_machine_type_series<T: Into<String>>(self, v: T) -> Self
Sets the value of machine_type_series.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_machine_type_series("example");Sourcepub fn set_machine_type<T: Into<String>>(self, v: T) -> Self
pub fn set_machine_type<T: Into<String>>(self, v: T) -> Self
Sets the value of machine_type.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_machine_type("example");Sets the value of network_tags.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_network_tags(["a", "b", "c"]);Sourcepub fn set_network_interfaces<T, V>(self, v: T) -> Self
pub fn set_network_interfaces<T, V>(self, v: T) -> Self
Sets the value of network_interfaces.
§Example
use google_cloud_vmmigration_v1::model::NetworkInterface;
let x = DisksMigrationVmTargetDefaults::new()
.set_network_interfaces([
NetworkInterface::default()/* use setters */,
NetworkInterface::default()/* use (different) setters */,
]);Sourcepub fn set_service_account<T: Into<String>>(self, v: T) -> Self
pub fn set_service_account<T: Into<String>>(self, v: T) -> Self
Sets the value of service_account.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_service_account("example");Sourcepub fn set_compute_scheduling<T>(self, v: T) -> Selfwhere
T: Into<ComputeScheduling>,
pub fn set_compute_scheduling<T>(self, v: T) -> Selfwhere
T: Into<ComputeScheduling>,
Sets the value of compute_scheduling.
§Example
use google_cloud_vmmigration_v1::model::ComputeScheduling;
let x = DisksMigrationVmTargetDefaults::new().set_compute_scheduling(ComputeScheduling::default()/* use setters */);Sourcepub fn set_or_clear_compute_scheduling<T>(self, v: Option<T>) -> Selfwhere
T: Into<ComputeScheduling>,
pub fn set_or_clear_compute_scheduling<T>(self, v: Option<T>) -> Selfwhere
T: Into<ComputeScheduling>,
Sets or clears the value of compute_scheduling.
§Example
use google_cloud_vmmigration_v1::model::ComputeScheduling;
let x = DisksMigrationVmTargetDefaults::new().set_or_clear_compute_scheduling(Some(ComputeScheduling::default()/* use setters */));
let x = DisksMigrationVmTargetDefaults::new().set_or_clear_compute_scheduling(None::<ComputeScheduling>);Sourcepub fn set_secure_boot<T: Into<bool>>(self, v: T) -> Self
pub fn set_secure_boot<T: Into<bool>>(self, v: T) -> Self
Sets the value of secure_boot.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_secure_boot(true);Sourcepub fn set_enable_vtpm<T: Into<bool>>(self, v: T) -> Self
pub fn set_enable_vtpm<T: Into<bool>>(self, v: T) -> Self
Sets the value of enable_vtpm.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_enable_vtpm(true);Sourcepub fn set_enable_integrity_monitoring<T: Into<bool>>(self, v: T) -> Self
pub fn set_enable_integrity_monitoring<T: Into<bool>>(self, v: T) -> Self
Sets the value of enable_integrity_monitoring.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_enable_integrity_monitoring(true);Sourcepub fn set_metadata<T, K, V>(self, v: T) -> Self
pub fn set_metadata<T, K, V>(self, v: T) -> Self
Sourcepub fn set_additional_licenses<T, V>(self, v: T) -> Self
pub fn set_additional_licenses<T, V>(self, v: T) -> Self
Sets the value of additional_licenses.
§Example
let x = DisksMigrationVmTargetDefaults::new().set_additional_licenses(["a", "b", "c"]);Sourcepub fn set_hostname<T: Into<String>>(self, v: T) -> Self
pub fn set_hostname<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_labels<T, K, V>(self, v: T) -> Self
pub fn set_labels<T, K, V>(self, v: T) -> Self
Sourcepub fn set_boot_disk_defaults<T>(self, v: T) -> Selfwhere
T: Into<BootDiskDefaults>,
pub fn set_boot_disk_defaults<T>(self, v: T) -> Selfwhere
T: Into<BootDiskDefaults>,
Sets the value of boot_disk_defaults.
§Example
use google_cloud_vmmigration_v1::model::BootDiskDefaults;
let x = DisksMigrationVmTargetDefaults::new().set_boot_disk_defaults(BootDiskDefaults::default()/* use setters */);Sourcepub fn set_or_clear_boot_disk_defaults<T>(self, v: Option<T>) -> Selfwhere
T: Into<BootDiskDefaults>,
pub fn set_or_clear_boot_disk_defaults<T>(self, v: Option<T>) -> Selfwhere
T: Into<BootDiskDefaults>,
Sets or clears the value of boot_disk_defaults.
§Example
use google_cloud_vmmigration_v1::model::BootDiskDefaults;
let x = DisksMigrationVmTargetDefaults::new().set_or_clear_boot_disk_defaults(Some(BootDiskDefaults::default()/* use setters */));
let x = DisksMigrationVmTargetDefaults::new().set_or_clear_boot_disk_defaults(None::<BootDiskDefaults>);Sourcepub fn set_encryption<T>(self, v: T) -> Selfwhere
T: Into<Encryption>,
pub fn set_encryption<T>(self, v: T) -> Selfwhere
T: Into<Encryption>,
Sets the value of encryption.
§Example
use google_cloud_vmmigration_v1::model::Encryption;
let x = DisksMigrationVmTargetDefaults::new().set_encryption(Encryption::default()/* use setters */);Sourcepub fn set_or_clear_encryption<T>(self, v: Option<T>) -> Selfwhere
T: Into<Encryption>,
pub fn set_or_clear_encryption<T>(self, v: Option<T>) -> Selfwhere
T: Into<Encryption>,
Sets or clears the value of encryption.
§Example
use google_cloud_vmmigration_v1::model::Encryption;
let x = DisksMigrationVmTargetDefaults::new().set_or_clear_encryption(Some(Encryption::default()/* use setters */));
let x = DisksMigrationVmTargetDefaults::new().set_or_clear_encryption(None::<Encryption>);Trait Implementations§
Source§impl Clone for DisksMigrationVmTargetDefaults
impl Clone for DisksMigrationVmTargetDefaults
Source§fn clone(&self) -> DisksMigrationVmTargetDefaults
fn clone(&self) -> DisksMigrationVmTargetDefaults
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Default for DisksMigrationVmTargetDefaults
impl Default for DisksMigrationVmTargetDefaults
Source§fn default() -> DisksMigrationVmTargetDefaults
fn default() -> DisksMigrationVmTargetDefaults
Source§impl PartialEq for DisksMigrationVmTargetDefaults
impl PartialEq for DisksMigrationVmTargetDefaults
Source§fn eq(&self, other: &DisksMigrationVmTargetDefaults) -> bool
fn eq(&self, other: &DisksMigrationVmTargetDefaults) -> bool
self and other values to be equal, and is used by ==.