#[non_exhaustive]pub struct Instance {Show 40 fields
pub name: String,
pub create_time: Option<Timestamp>,
pub update_time: Option<Timestamp>,
pub labels: HashMap<String, String>,
pub state: State,
pub state_info: Option<StateInfo>,
pub uid: String,
pub replica_count: Option<i32>,
pub authorization_mode: AuthorizationMode,
pub transit_encryption_mode: TransitEncryptionMode,
pub shard_count: i32,
pub discovery_endpoints: Vec<DiscoveryEndpoint>,
pub node_type: NodeType,
pub persistence_config: Option<PersistenceConfig>,
pub engine_version: String,
pub engine_configs: HashMap<String, String>,
pub node_config: Option<NodeConfig>,
pub zone_distribution_config: Option<ZoneDistributionConfig>,
pub deletion_protection_enabled: Option<bool>,
pub psc_auto_connections: Vec<PscAutoConnection>,
pub psc_attachment_details: Vec<PscAttachmentDetail>,
pub endpoints: Vec<InstanceEndpoint>,
pub mode: Mode,
pub simulate_maintenance_event: Option<bool>,
pub ondemand_maintenance: Option<bool>,
pub satisfies_pzs: Option<bool>,
pub satisfies_pzi: Option<bool>,
pub maintenance_policy: Option<MaintenancePolicy>,
pub maintenance_schedule: Option<MaintenanceSchedule>,
pub cross_instance_replication_config: Option<CrossInstanceReplicationConfig>,
pub async_instance_endpoints_deletion_enabled: Option<bool>,
pub kms_key: Option<String>,
pub encryption_info: Option<EncryptionInfo>,
pub backup_collection: Option<String>,
pub automated_backup_config: Option<AutomatedBackupConfig>,
pub maintenance_version: Option<String>,
pub effective_maintenance_version: Option<String>,
pub available_maintenance_versions: Vec<String>,
pub allow_fewer_zones_deployment: bool,
pub import_sources: Option<ImportSources>,
/* private fields */
}Expand description
A Memorystore instance.
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.name: StringIdentifier. Unique name of the instance. Format: projects/{project}/locations/{location}/instances/{instance}
create_time: Option<Timestamp>Output only. Creation timestamp of the instance.
update_time: Option<Timestamp>Output only. Latest update timestamp of the instance.
labels: HashMap<String, String>Optional. Labels to represent user-provided metadata.
state: StateOutput only. Current state of the instance.
state_info: Option<StateInfo>Output only. Additional information about the state of the instance.
uid: StringOutput only. System assigned, unique identifier for the instance.
replica_count: Option<i32>Optional. Number of replica nodes per shard. If omitted the default is 0 replicas.
Optional. Immutable. Authorization mode of the instance.
transit_encryption_mode: TransitEncryptionModeOptional. Immutable. In-transit encryption mode of the instance.
shard_count: i32Optional. Number of shards for the instance.
discovery_endpoints: Vec<DiscoveryEndpoint>Output only. Deprecated: The discovery_endpoints parameter is deprecated. As a result, it will not be populated if the connections are created using endpoints parameter. Instead of this parameter, for discovery, use endpoints.connections.pscConnection and endpoints.connections.pscAutoConnection with connectionType CONNECTION_TYPE_DISCOVERY.
node_type: NodeTypeOptional. Machine type for individual nodes of the instance.
persistence_config: Option<PersistenceConfig>Optional. Persistence configuration of the instance.
engine_version: StringOptional. Engine version of the instance.
engine_configs: HashMap<String, String>Optional. User-provided engine configurations for the instance.
node_config: Option<NodeConfig>Output only. Configuration of individual nodes of the instance.
zone_distribution_config: Option<ZoneDistributionConfig>Optional. Immutable. Zone distribution configuration of the instance for node allocation.
deletion_protection_enabled: Option<bool>Optional. If set to true deletion of the instance will fail.
psc_auto_connections: Vec<PscAutoConnection>Optional. Immutable. Deprecated: Use the endpoints.connections.psc_auto_connection value instead.
psc_attachment_details: Vec<PscAttachmentDetail>Output only. Service attachment details to configure PSC connections.
endpoints: Vec<InstanceEndpoint>Optional. Endpoints for the instance.
mode: ModeOptional. The mode config for the instance.
simulate_maintenance_event: Option<bool>Optional. Input only. Simulate a maintenance event.
ondemand_maintenance: Option<bool>Optional. Input only. Ondemand maintenance for the instance.
satisfies_pzs: Option<bool>Optional. Output only. Reserved for future use.
satisfies_pzi: Option<bool>Optional. Output only. Reserved for future use.
maintenance_policy: Option<MaintenancePolicy>Optional. The maintenance policy for the instance. If not provided, the maintenance event will be performed based on Memorystore internal rollout schedule.
maintenance_schedule: Option<MaintenanceSchedule>Output only. Published maintenance schedule.
cross_instance_replication_config: Option<CrossInstanceReplicationConfig>Optional. The config for cross instance replication.
async_instance_endpoints_deletion_enabled: Option<bool>Optional. If true, instance endpoints that are created and registered by customers can be deleted asynchronously. That is, such an instance endpoint can be de-registered before the forwarding rules in the instance endpoint are deleted.
kms_key: Option<String>Optional. The KMS key used to encrypt the at-rest data of the cluster.
encryption_info: Option<EncryptionInfo>Output only. Encryption information of the data at rest of the cluster.
backup_collection: Option<String>Output only. The backup collection full resource name. Example: projects/{project}/locations/{location}/backupCollections/{collection}
automated_backup_config: Option<AutomatedBackupConfig>Optional. The automated backup config for the instance.
maintenance_version: Option<String>Optional. This field can be used to trigger self service update to indicate the desired maintenance version. The input to this field can be determined by the available_maintenance_versions field.
effective_maintenance_version: Option<String>Output only. This field represents the actual maintenance version of the instance.
available_maintenance_versions: Vec<String>Output only. This field is used to determine the available maintenance versions for the self service update.
allow_fewer_zones_deployment: boolOptional. Immutable. Deprecated, do not use.
import_sources: Option<ImportSources>The source to import from.
Implementations§
Source§impl Instance
impl Instance
pub fn new() -> Self
Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
§Example
use wkt::Timestamp;
let x = Instance::new().set_create_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
§Example
use wkt::Timestamp;
let x = Instance::new().set_or_clear_create_time(Some(Timestamp::default()/* use setters */));
let x = Instance::new().set_or_clear_create_time(None::<Timestamp>);Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
§Example
use wkt::Timestamp;
let x = Instance::new().set_update_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
§Example
use wkt::Timestamp;
let x = Instance::new().set_or_clear_update_time(Some(Timestamp::default()/* use setters */));
let x = Instance::new().set_or_clear_update_time(None::<Timestamp>);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_state_info<T>(self, v: T) -> Self
pub fn set_state_info<T>(self, v: T) -> Self
Sets the value of state_info.
§Example
use google_cloud_memorystore_v1::model::instance::StateInfo;
let x = Instance::new().set_state_info(StateInfo::default()/* use setters */);Sourcepub fn set_or_clear_state_info<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_state_info<T>(self, v: Option<T>) -> Self
Sets or clears the value of state_info.
§Example
use google_cloud_memorystore_v1::model::instance::StateInfo;
let x = Instance::new().set_or_clear_state_info(Some(StateInfo::default()/* use setters */));
let x = Instance::new().set_or_clear_state_info(None::<StateInfo>);Sourcepub fn set_replica_count<T>(self, v: T) -> Self
pub fn set_replica_count<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_replica_count<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_replica_count<T>(self, v: Option<T>) -> Self
Sets or clears the value of replica_count.
§Example
let x = Instance::new().set_or_clear_replica_count(Some(42));
let x = Instance::new().set_or_clear_replica_count(None::<i32>);Sets the value of authorization_mode.
§Example
use google_cloud_memorystore_v1::model::instance::AuthorizationMode;
let x0 = Instance::new().set_authorization_mode(AuthorizationMode::AuthDisabled);
let x1 = Instance::new().set_authorization_mode(AuthorizationMode::IamAuth);Sourcepub fn set_transit_encryption_mode<T: Into<TransitEncryptionMode>>(
self,
v: T,
) -> Self
pub fn set_transit_encryption_mode<T: Into<TransitEncryptionMode>>( self, v: T, ) -> Self
Sets the value of transit_encryption_mode.
§Example
use google_cloud_memorystore_v1::model::instance::TransitEncryptionMode;
let x0 = Instance::new().set_transit_encryption_mode(TransitEncryptionMode::TransitEncryptionDisabled);
let x1 = Instance::new().set_transit_encryption_mode(TransitEncryptionMode::ServerAuthentication);Sourcepub fn set_shard_count<T: Into<i32>>(self, v: T) -> Self
pub fn set_shard_count<T: Into<i32>>(self, v: T) -> Self
Sourcepub fn set_discovery_endpoints<T, V>(self, v: T) -> Self
👎Deprecated
pub fn set_discovery_endpoints<T, V>(self, v: T) -> Self
Sets the value of discovery_endpoints.
§Example
use google_cloud_memorystore_v1::model::DiscoveryEndpoint;
let x = Instance::new()
.set_discovery_endpoints([
DiscoveryEndpoint::default()/* use setters */,
DiscoveryEndpoint::default()/* use (different) setters */,
]);Sourcepub fn set_node_type<T: Into<NodeType>>(self, v: T) -> Self
pub fn set_node_type<T: Into<NodeType>>(self, v: T) -> Self
Sourcepub fn set_persistence_config<T>(self, v: T) -> Selfwhere
T: Into<PersistenceConfig>,
pub fn set_persistence_config<T>(self, v: T) -> Selfwhere
T: Into<PersistenceConfig>,
Sets the value of persistence_config.
§Example
use google_cloud_memorystore_v1::model::PersistenceConfig;
let x = Instance::new().set_persistence_config(PersistenceConfig::default()/* use setters */);Sourcepub fn set_or_clear_persistence_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<PersistenceConfig>,
pub fn set_or_clear_persistence_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<PersistenceConfig>,
Sets or clears the value of persistence_config.
§Example
use google_cloud_memorystore_v1::model::PersistenceConfig;
let x = Instance::new().set_or_clear_persistence_config(Some(PersistenceConfig::default()/* use setters */));
let x = Instance::new().set_or_clear_persistence_config(None::<PersistenceConfig>);Sourcepub fn set_engine_version<T: Into<String>>(self, v: T) -> Self
pub fn set_engine_version<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_engine_configs<T, K, V>(self, v: T) -> Self
pub fn set_engine_configs<T, K, V>(self, v: T) -> Self
Sets the value of engine_configs.
§Example
let x = Instance::new().set_engine_configs([
("key0", "abc"),
("key1", "xyz"),
]);Sourcepub fn set_node_config<T>(self, v: T) -> Selfwhere
T: Into<NodeConfig>,
pub fn set_node_config<T>(self, v: T) -> Selfwhere
T: Into<NodeConfig>,
Sets the value of node_config.
§Example
use google_cloud_memorystore_v1::model::NodeConfig;
let x = Instance::new().set_node_config(NodeConfig::default()/* use setters */);Sourcepub fn set_or_clear_node_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<NodeConfig>,
pub fn set_or_clear_node_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<NodeConfig>,
Sets or clears the value of node_config.
§Example
use google_cloud_memorystore_v1::model::NodeConfig;
let x = Instance::new().set_or_clear_node_config(Some(NodeConfig::default()/* use setters */));
let x = Instance::new().set_or_clear_node_config(None::<NodeConfig>);Sourcepub fn set_zone_distribution_config<T>(self, v: T) -> Selfwhere
T: Into<ZoneDistributionConfig>,
pub fn set_zone_distribution_config<T>(self, v: T) -> Selfwhere
T: Into<ZoneDistributionConfig>,
Sets the value of zone_distribution_config.
§Example
use google_cloud_memorystore_v1::model::ZoneDistributionConfig;
let x = Instance::new().set_zone_distribution_config(ZoneDistributionConfig::default()/* use setters */);Sourcepub fn set_or_clear_zone_distribution_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<ZoneDistributionConfig>,
pub fn set_or_clear_zone_distribution_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<ZoneDistributionConfig>,
Sets or clears the value of zone_distribution_config.
§Example
use google_cloud_memorystore_v1::model::ZoneDistributionConfig;
let x = Instance::new().set_or_clear_zone_distribution_config(Some(ZoneDistributionConfig::default()/* use setters */));
let x = Instance::new().set_or_clear_zone_distribution_config(None::<ZoneDistributionConfig>);Sourcepub fn set_deletion_protection_enabled<T>(self, v: T) -> Self
pub fn set_deletion_protection_enabled<T>(self, v: T) -> Self
Sets the value of deletion_protection_enabled.
§Example
let x = Instance::new().set_deletion_protection_enabled(true);Sourcepub fn set_or_clear_deletion_protection_enabled<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_deletion_protection_enabled<T>(self, v: Option<T>) -> Self
Sets or clears the value of deletion_protection_enabled.
§Example
let x = Instance::new().set_or_clear_deletion_protection_enabled(Some(false));
let x = Instance::new().set_or_clear_deletion_protection_enabled(None::<bool>);Sourcepub fn set_psc_auto_connections<T, V>(self, v: T) -> Self
👎Deprecated
pub fn set_psc_auto_connections<T, V>(self, v: T) -> Self
Sets the value of psc_auto_connections.
§Example
use google_cloud_memorystore_v1::model::PscAutoConnection;
let x = Instance::new()
.set_psc_auto_connections([
PscAutoConnection::default()/* use setters */,
PscAutoConnection::default()/* use (different) setters */,
]);Sourcepub fn set_psc_attachment_details<T, V>(self, v: T) -> Self
pub fn set_psc_attachment_details<T, V>(self, v: T) -> Self
Sets the value of psc_attachment_details.
§Example
use google_cloud_memorystore_v1::model::PscAttachmentDetail;
let x = Instance::new()
.set_psc_attachment_details([
PscAttachmentDetail::default()/* use setters */,
PscAttachmentDetail::default()/* use (different) setters */,
]);Sourcepub fn set_endpoints<T, V>(self, v: T) -> Self
pub fn set_endpoints<T, V>(self, v: T) -> Self
Sourcepub fn set_simulate_maintenance_event<T>(self, v: T) -> Self
pub fn set_simulate_maintenance_event<T>(self, v: T) -> Self
Sets the value of simulate_maintenance_event.
§Example
let x = Instance::new().set_simulate_maintenance_event(true);Sourcepub fn set_or_clear_simulate_maintenance_event<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_simulate_maintenance_event<T>(self, v: Option<T>) -> Self
Sets or clears the value of simulate_maintenance_event.
§Example
let x = Instance::new().set_or_clear_simulate_maintenance_event(Some(false));
let x = Instance::new().set_or_clear_simulate_maintenance_event(None::<bool>);Sourcepub fn set_ondemand_maintenance<T>(self, v: T) -> Self
👎Deprecated
pub fn set_ondemand_maintenance<T>(self, v: T) -> Self
Sets the value of ondemand_maintenance.
§Example
let x = Instance::new().set_ondemand_maintenance(true);Sourcepub fn set_or_clear_ondemand_maintenance<T>(self, v: Option<T>) -> Self
👎Deprecated
pub fn set_or_clear_ondemand_maintenance<T>(self, v: Option<T>) -> Self
Sets or clears the value of ondemand_maintenance.
§Example
let x = Instance::new().set_or_clear_ondemand_maintenance(Some(false));
let x = Instance::new().set_or_clear_ondemand_maintenance(None::<bool>);Sourcepub fn set_satisfies_pzs<T>(self, v: T) -> Self
pub fn set_satisfies_pzs<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_satisfies_pzs<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_satisfies_pzs<T>(self, v: Option<T>) -> Self
Sets or clears the value of satisfies_pzs.
§Example
let x = Instance::new().set_or_clear_satisfies_pzs(Some(false));
let x = Instance::new().set_or_clear_satisfies_pzs(None::<bool>);Sourcepub fn set_satisfies_pzi<T>(self, v: T) -> Self
pub fn set_satisfies_pzi<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_satisfies_pzi<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_satisfies_pzi<T>(self, v: Option<T>) -> Self
Sets or clears the value of satisfies_pzi.
§Example
let x = Instance::new().set_or_clear_satisfies_pzi(Some(false));
let x = Instance::new().set_or_clear_satisfies_pzi(None::<bool>);Sourcepub fn set_maintenance_policy<T>(self, v: T) -> Selfwhere
T: Into<MaintenancePolicy>,
pub fn set_maintenance_policy<T>(self, v: T) -> Selfwhere
T: Into<MaintenancePolicy>,
Sets the value of maintenance_policy.
§Example
use google_cloud_memorystore_v1::model::MaintenancePolicy;
let x = Instance::new().set_maintenance_policy(MaintenancePolicy::default()/* use setters */);Sourcepub fn set_or_clear_maintenance_policy<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenancePolicy>,
pub fn set_or_clear_maintenance_policy<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenancePolicy>,
Sets or clears the value of maintenance_policy.
§Example
use google_cloud_memorystore_v1::model::MaintenancePolicy;
let x = Instance::new().set_or_clear_maintenance_policy(Some(MaintenancePolicy::default()/* use setters */));
let x = Instance::new().set_or_clear_maintenance_policy(None::<MaintenancePolicy>);Sourcepub fn set_maintenance_schedule<T>(self, v: T) -> Selfwhere
T: Into<MaintenanceSchedule>,
pub fn set_maintenance_schedule<T>(self, v: T) -> Selfwhere
T: Into<MaintenanceSchedule>,
Sets the value of maintenance_schedule.
§Example
use google_cloud_memorystore_v1::model::MaintenanceSchedule;
let x = Instance::new().set_maintenance_schedule(MaintenanceSchedule::default()/* use setters */);Sourcepub fn set_or_clear_maintenance_schedule<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenanceSchedule>,
pub fn set_or_clear_maintenance_schedule<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenanceSchedule>,
Sets or clears the value of maintenance_schedule.
§Example
use google_cloud_memorystore_v1::model::MaintenanceSchedule;
let x = Instance::new().set_or_clear_maintenance_schedule(Some(MaintenanceSchedule::default()/* use setters */));
let x = Instance::new().set_or_clear_maintenance_schedule(None::<MaintenanceSchedule>);Sourcepub fn set_cross_instance_replication_config<T>(self, v: T) -> Selfwhere
T: Into<CrossInstanceReplicationConfig>,
pub fn set_cross_instance_replication_config<T>(self, v: T) -> Selfwhere
T: Into<CrossInstanceReplicationConfig>,
Sets the value of cross_instance_replication_config.
§Example
use google_cloud_memorystore_v1::model::CrossInstanceReplicationConfig;
let x = Instance::new().set_cross_instance_replication_config(CrossInstanceReplicationConfig::default()/* use setters */);Sourcepub fn set_or_clear_cross_instance_replication_config<T>(
self,
v: Option<T>,
) -> Selfwhere
T: Into<CrossInstanceReplicationConfig>,
pub fn set_or_clear_cross_instance_replication_config<T>(
self,
v: Option<T>,
) -> Selfwhere
T: Into<CrossInstanceReplicationConfig>,
Sets or clears the value of cross_instance_replication_config.
§Example
use google_cloud_memorystore_v1::model::CrossInstanceReplicationConfig;
let x = Instance::new().set_or_clear_cross_instance_replication_config(Some(CrossInstanceReplicationConfig::default()/* use setters */));
let x = Instance::new().set_or_clear_cross_instance_replication_config(None::<CrossInstanceReplicationConfig>);Sourcepub fn set_async_instance_endpoints_deletion_enabled<T>(self, v: T) -> Self
pub fn set_async_instance_endpoints_deletion_enabled<T>(self, v: T) -> Self
Sets the value of async_instance_endpoints_deletion_enabled.
§Example
let x = Instance::new().set_async_instance_endpoints_deletion_enabled(true);Sourcepub fn set_or_clear_async_instance_endpoints_deletion_enabled<T>(
self,
v: Option<T>,
) -> Self
pub fn set_or_clear_async_instance_endpoints_deletion_enabled<T>( self, v: Option<T>, ) -> Self
Sets or clears the value of async_instance_endpoints_deletion_enabled.
§Example
let x = Instance::new().set_or_clear_async_instance_endpoints_deletion_enabled(Some(false));
let x = Instance::new().set_or_clear_async_instance_endpoints_deletion_enabled(None::<bool>);Sourcepub fn set_kms_key<T>(self, v: T) -> Self
pub fn set_kms_key<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_kms_key<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_kms_key<T>(self, v: Option<T>) -> Self
Sourcepub fn set_encryption_info<T>(self, v: T) -> Selfwhere
T: Into<EncryptionInfo>,
pub fn set_encryption_info<T>(self, v: T) -> Selfwhere
T: Into<EncryptionInfo>,
Sets the value of encryption_info.
§Example
use google_cloud_memorystore_v1::model::EncryptionInfo;
let x = Instance::new().set_encryption_info(EncryptionInfo::default()/* use setters */);Sourcepub fn set_or_clear_encryption_info<T>(self, v: Option<T>) -> Selfwhere
T: Into<EncryptionInfo>,
pub fn set_or_clear_encryption_info<T>(self, v: Option<T>) -> Selfwhere
T: Into<EncryptionInfo>,
Sets or clears the value of encryption_info.
§Example
use google_cloud_memorystore_v1::model::EncryptionInfo;
let x = Instance::new().set_or_clear_encryption_info(Some(EncryptionInfo::default()/* use setters */));
let x = Instance::new().set_or_clear_encryption_info(None::<EncryptionInfo>);Sourcepub fn set_backup_collection<T>(self, v: T) -> Self
pub fn set_backup_collection<T>(self, v: T) -> Self
Sets the value of backup_collection.
§Example
let x = Instance::new().set_backup_collection("example");Sourcepub fn set_or_clear_backup_collection<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_backup_collection<T>(self, v: Option<T>) -> Self
Sets or clears the value of backup_collection.
§Example
let x = Instance::new().set_or_clear_backup_collection(Some("example"));
let x = Instance::new().set_or_clear_backup_collection(None::<String>);Sourcepub fn set_automated_backup_config<T>(self, v: T) -> Selfwhere
T: Into<AutomatedBackupConfig>,
pub fn set_automated_backup_config<T>(self, v: T) -> Selfwhere
T: Into<AutomatedBackupConfig>,
Sets the value of automated_backup_config.
§Example
use google_cloud_memorystore_v1::model::AutomatedBackupConfig;
let x = Instance::new().set_automated_backup_config(AutomatedBackupConfig::default()/* use setters */);Sourcepub fn set_or_clear_automated_backup_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<AutomatedBackupConfig>,
pub fn set_or_clear_automated_backup_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<AutomatedBackupConfig>,
Sets or clears the value of automated_backup_config.
§Example
use google_cloud_memorystore_v1::model::AutomatedBackupConfig;
let x = Instance::new().set_or_clear_automated_backup_config(Some(AutomatedBackupConfig::default()/* use setters */));
let x = Instance::new().set_or_clear_automated_backup_config(None::<AutomatedBackupConfig>);Sourcepub fn set_maintenance_version<T>(self, v: T) -> Self
pub fn set_maintenance_version<T>(self, v: T) -> Self
Sets the value of maintenance_version.
§Example
let x = Instance::new().set_maintenance_version("example");Sourcepub fn set_or_clear_maintenance_version<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_maintenance_version<T>(self, v: Option<T>) -> Self
Sets or clears the value of maintenance_version.
§Example
let x = Instance::new().set_or_clear_maintenance_version(Some("example"));
let x = Instance::new().set_or_clear_maintenance_version(None::<String>);Sourcepub fn set_effective_maintenance_version<T>(self, v: T) -> Self
pub fn set_effective_maintenance_version<T>(self, v: T) -> Self
Sets the value of effective_maintenance_version.
§Example
let x = Instance::new().set_effective_maintenance_version("example");Sourcepub fn set_or_clear_effective_maintenance_version<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_effective_maintenance_version<T>(self, v: Option<T>) -> Self
Sets or clears the value of effective_maintenance_version.
§Example
let x = Instance::new().set_or_clear_effective_maintenance_version(Some("example"));
let x = Instance::new().set_or_clear_effective_maintenance_version(None::<String>);Sourcepub fn set_available_maintenance_versions<T, V>(self, v: T) -> Self
pub fn set_available_maintenance_versions<T, V>(self, v: T) -> Self
Sets the value of available_maintenance_versions.
§Example
let x = Instance::new().set_available_maintenance_versions(["a", "b", "c"]);Sourcepub fn set_allow_fewer_zones_deployment<T: Into<bool>>(self, v: T) -> Self
👎Deprecated
pub fn set_allow_fewer_zones_deployment<T: Into<bool>>(self, v: T) -> Self
Sets the value of allow_fewer_zones_deployment.
§Example
let x = Instance::new().set_allow_fewer_zones_deployment(true);Sourcepub fn set_import_sources<T: Into<Option<ImportSources>>>(self, v: T) -> Self
pub fn set_import_sources<T: Into<Option<ImportSources>>>(self, v: T) -> Self
Sets the value of import_sources.
Note that all the setters affecting import_sources are mutually
exclusive.
§Example
use google_cloud_memorystore_v1::model::instance::GcsBackupSource;
let x = Instance::new().set_import_sources(Some(
google_cloud_memorystore_v1::model::instance::ImportSources::GcsSource(GcsBackupSource::default().into())));Sourcepub fn gcs_source(&self) -> Option<&Box<GcsBackupSource>>
pub fn gcs_source(&self) -> Option<&Box<GcsBackupSource>>
The value of import_sources
if it holds a GcsSource, None if the field is not set or
holds a different branch.
Sourcepub fn set_gcs_source<T: Into<Box<GcsBackupSource>>>(self, v: T) -> Self
pub fn set_gcs_source<T: Into<Box<GcsBackupSource>>>(self, v: T) -> Self
Sets the value of import_sources
to hold a GcsSource.
Note that all the setters affecting import_sources are
mutually exclusive.
§Example
use google_cloud_memorystore_v1::model::instance::GcsBackupSource;
let x = Instance::new().set_gcs_source(GcsBackupSource::default()/* use setters */);
assert!(x.gcs_source().is_some());
assert!(x.managed_backup_source().is_none());Sourcepub fn managed_backup_source(&self) -> Option<&Box<ManagedBackupSource>>
pub fn managed_backup_source(&self) -> Option<&Box<ManagedBackupSource>>
The value of import_sources
if it holds a ManagedBackupSource, None if the field is not set or
holds a different branch.
Sourcepub fn set_managed_backup_source<T: Into<Box<ManagedBackupSource>>>(
self,
v: T,
) -> Self
pub fn set_managed_backup_source<T: Into<Box<ManagedBackupSource>>>( self, v: T, ) -> Self
Sets the value of import_sources
to hold a ManagedBackupSource.
Note that all the setters affecting import_sources are
mutually exclusive.
§Example
use google_cloud_memorystore_v1::model::instance::ManagedBackupSource;
let x = Instance::new().set_managed_backup_source(ManagedBackupSource::default()/* use setters */);
assert!(x.managed_backup_source().is_some());
assert!(x.gcs_source().is_none());