#[non_exhaustive]pub struct Subnetwork {Show 32 fields
pub allow_subnet_cidr_routes_overlap: Option<bool>,
pub creation_timestamp: Option<String>,
pub description: Option<String>,
pub enable_flow_logs: Option<bool>,
pub external_ipv_6_prefix: Option<String>,
pub fingerprint: Option<Bytes>,
pub gateway_address: Option<String>,
pub id: Option<u64>,
pub internal_ipv_6_prefix: Option<String>,
pub ip_cidr_range: Option<String>,
pub ip_collection: Option<String>,
pub ipv_6_access_type: Option<Ipv6AccessType>,
pub ipv_6_cidr_range: Option<String>,
pub ipv_6_gce_endpoint: Option<Ipv6GceEndpoint>,
pub kind: Option<String>,
pub log_config: Option<SubnetworkLogConfig>,
pub name: Option<String>,
pub network: Option<String>,
pub params: Option<SubnetworkParams>,
pub private_ip_google_access: Option<bool>,
pub private_ipv_6_google_access: Option<PrivateIpv6GoogleAccess>,
pub purpose: Option<Purpose>,
pub region: Option<String>,
pub reserved_internal_range: Option<String>,
pub role: Option<Role>,
pub secondary_ip_ranges: Vec<SubnetworkSecondaryRange>,
pub self_link: Option<String>,
pub stack_type: Option<StackType>,
pub state: Option<State>,
pub system_reserved_external_ipv_6_ranges: Vec<String>,
pub system_reserved_internal_ipv_6_ranges: Vec<String>,
pub utilization_details: Option<SubnetworkUtilizationDetails>,
/* private fields */
}subnetworks only.Expand description
Represents a Subnetwork resource.
A subnetwork (also known as a subnet) is a logical partition of a Virtual Private Cloud network with one primary IP range and zero or more secondary IP ranges. For more information, read Virtual Private Cloud (VPC) Network.
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.allow_subnet_cidr_routes_overlap: Option<bool>Whether this subnetwork’s ranges can conflict with existing static routes. Setting this to true allows this subnetwork’s primary and secondary ranges to overlap with (and contain) static routes that have already been configured on the corresponding network.
For example if a static route has range 10.1.0.0/16, a subnet range 10.0.0.0/8 could only be created if allow_conflicting_routes=true.
Overlapping is only allowed on subnetwork operations; routes whose ranges conflict with this subnetwork’s ranges won’t be allowed unless route.allow_conflicting_subnetworks is set to true.
Typically packets destined to IPs within the subnetwork (which may contain private/sensitive data) are prevented from leaving the virtual network. Setting this field to true will disable this feature.
The default value is false and applies to all existing subnetworks and automatically created subnetworks.
This field cannot be set to true at resource creation time.
creation_timestamp: Option<String>Output only. [Output Only] Creation timestamp inRFC3339 text format.
description: Option<String>An optional description of this resource. Provide this property when you create the resource. This field can be set only at resource creation time.
enable_flow_logs: Option<bool>Whether to enable flow logging for this subnetwork. If this field is not explicitly set, it will not appear in get listings. If not set the default behavior is determined by the org policy, if there is no org policy specified, then it will default to disabled. This field isn’t supported if the subnet purpose field is set toREGIONAL_MANAGED_PROXY. It is recommended to uselogConfig.enable field instead.
external_ipv_6_prefix: Option<String>The external IPv6 address range that is owned by this subnetwork.
fingerprint: Option<Bytes>Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a Subnetwork. An up-to-date fingerprint must be provided in order to update the Subnetwork, otherwise the request will fail with error 412 conditionNotMet.
To see the latest fingerprint, make a get() request to retrieve a Subnetwork.
gateway_address: Option<String>Output only. [Output Only] The gateway address for default routes to reach destination addresses outside this subnetwork.
id: Option<u64>Output only. [Output Only] The unique identifier for the resource. This identifier is defined by the server.
internal_ipv_6_prefix: Option<String>The internal IPv6 address range that is owned by this subnetwork.
ip_cidr_range: Option<String>The range of internal addresses that are owned by this subnetwork. Provide this property when you create the subnetwork. For example,10.0.0.0/8 or 100.64.0.0/10. Ranges must be unique and non-overlapping within a network. Only IPv4 is supported. This field is set at resource creation time. The range can be any range listed in theValid ranges list. The range can be expanded after creation usingexpandIpCidrRange.
ip_collection: Option<String>Reference to the source of IP, like a PublicDelegatedPrefix (PDP) for BYOIP. The PDP must be a sub-PDP in EXTERNAL_IPV6_SUBNETWORK_CREATION or INTERNAL_IPV6_SUBNETWORK_CREATION mode.
Use one of the following formats to specify a sub-PDP when creating a dual stack or IPv6-only subnetwork with external access using BYOIP:
§Full resource URL, as inhttps://www.googleapis.com/compute/v1/projects/projectId/regions/region/publicDelegatedPrefixes/sub-pdp-name
Partial URL, as in
- projects/projectId/regions/region/publicDelegatedPrefixes/sub-pdp-name
- regions/region/publicDelegatedPrefixes/sub-pdp-nameipv_6_access_type: Option<Ipv6AccessType>The access type of IPv6 address this subnet holds. It’s immutable and can only be specified during creation or the first time the subnet is updated into IPV4_IPV6 dual stack.
ipv_6_cidr_range: Option<String>Output only. [Output Only] This field is for internal use.
ipv_6_gce_endpoint: Option<Ipv6GceEndpoint>Output only. [Output Only] Possible endpoints of this subnetwork. It can be one of the following:
- VM_ONLY: The subnetwork can be used for creating instances and IPv6 addresses with VM endpoint type. Such a subnetwork gets external IPv6 ranges from a public delegated prefix and cannot be used to create NetLb.
- VM_AND_FR: The subnetwork can be used for creating both VM instances and Forwarding Rules. It can also be used to reserve IPv6 addresses with both VM and FR endpoint types. Such a subnetwork gets its IPv6 range from Google IP Pool directly.
kind: Option<String>Output only. [Output Only] Type of the resource. Always compute#subnetwork for Subnetwork resources.
log_config: Option<SubnetworkLogConfig>This field denotes the VPC flow logging options for this subnetwork. If logging is enabled, logs are exported to Cloud Logging.
name: Option<String>The name of the resource, provided by the client when initially creating
the resource. The name must be 1-63 characters long, and comply withRFC1035.
Specifically, the name must be 1-63 characters long and match the regular
expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first
character must be a lowercase letter, and all following characters must
be a dash, lowercase letter, or digit, except the last character, which
cannot be a dash.
network: Option<String>The URL of the network to which this subnetwork belongs, provided by the client when initially creating the subnetwork. This field can be set only at resource creation time.
params: Option<SubnetworkParams>Input only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
private_ip_google_access: Option<bool>Whether the VMs in this subnet can access Google services without assigned external IP addresses. This field can be both set at resource creation time and updated using setPrivateIpGoogleAccess.
private_ipv_6_google_access: Option<PrivateIpv6GoogleAccess>This field is for internal use.
This field can be both set at resource creation time and updated usingpatch.
purpose: Option<Purpose>§region: Option<String>URL of the region where the Subnetwork resides. This field can be set only at resource creation time.
reserved_internal_range: Option<String>The URL of the reserved internal range.
role: Option<Role>The role of subnetwork. Currently, this field is only used when purpose is set to GLOBAL_MANAGED_PROXY orREGIONAL_MANAGED_PROXY. The value can be set toACTIVE or BACKUP. An ACTIVE subnetwork is one that is currently being used for Envoy-based load balancers in a region. A BACKUP subnetwork is one that is ready to be promoted to ACTIVE or is currently draining. This field can be updated with a patch request.
secondary_ip_ranges: Vec<SubnetworkSecondaryRange>An array of configurations for secondary IP ranges for VM instances contained in this subnetwork. The primary IP of such VM must belong to the primary ipCidrRange of the subnetwork. The alias IPs may belong to either primary or secondary ranges. This field can be updated with apatch request.
self_link: Option<String>[Output Only] Server-defined URL for the resource.
stack_type: Option<StackType>The stack type for the subnet. If set to IPV4_ONLY, new VMs in the subnet are assigned IPv4 addresses only. If set toIPV4_IPV6, new VMs in the subnet can be assigned both IPv4 and IPv6 addresses. If not specified, IPV4_ONLY is used.
This field can be both set at resource creation time and updated usingpatch.
state: Option<State>Output only. [Output Only] The state of the subnetwork, which can be one of the following values:READY: Subnetwork is created and ready to useDRAINING: only applicable to subnetworks that have the purpose set to INTERNAL_HTTPS_LOAD_BALANCER and indicates that connections to the load balancer are being drained. A subnetwork that is draining cannot be used or modified until it reaches a status ofREADY
system_reserved_external_ipv_6_ranges: Vec<String>Output only. [Output Only] The array of external IPv6 network ranges reserved from the subnetwork’s external IPv6 range for system use.
system_reserved_internal_ipv_6_ranges: Vec<String>Output only. [Output Only] The array of internal IPv6 network ranges reserved from the subnetwork’s internal IPv6 range for system use.
utilization_details: Option<SubnetworkUtilizationDetails>Output only. [Output Only] The current IP utilization of all subnetwork ranges. Contains the total number of allocated and free IPs in each range.
Implementations§
Source§impl Subnetwork
impl Subnetwork
pub fn new() -> Self
Sourcepub fn set_allow_subnet_cidr_routes_overlap<T>(self, v: T) -> Self
pub fn set_allow_subnet_cidr_routes_overlap<T>(self, v: T) -> Self
Sets the value of allow_subnet_cidr_routes_overlap.
§Example
let x = Subnetwork::new().set_allow_subnet_cidr_routes_overlap(true);Sourcepub fn set_or_clear_allow_subnet_cidr_routes_overlap<T>(
self,
v: Option<T>,
) -> Self
pub fn set_or_clear_allow_subnet_cidr_routes_overlap<T>( self, v: Option<T>, ) -> Self
Sets or clears the value of allow_subnet_cidr_routes_overlap.
§Example
let x = Subnetwork::new().set_or_clear_allow_subnet_cidr_routes_overlap(Some(false));
let x = Subnetwork::new().set_or_clear_allow_subnet_cidr_routes_overlap(None::<bool>);Sourcepub fn set_creation_timestamp<T>(self, v: T) -> Self
pub fn set_creation_timestamp<T>(self, v: T) -> Self
Sets the value of creation_timestamp.
§Example
let x = Subnetwork::new().set_creation_timestamp("example");Sourcepub fn set_or_clear_creation_timestamp<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_creation_timestamp<T>(self, v: Option<T>) -> Self
Sets or clears the value of creation_timestamp.
§Example
let x = Subnetwork::new().set_or_clear_creation_timestamp(Some("example"));
let x = Subnetwork::new().set_or_clear_creation_timestamp(None::<String>);Sourcepub fn set_description<T>(self, v: T) -> Self
pub fn set_description<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_description<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_description<T>(self, v: Option<T>) -> Self
Sets or clears the value of description.
§Example
let x = Subnetwork::new().set_or_clear_description(Some("example"));
let x = Subnetwork::new().set_or_clear_description(None::<String>);Sourcepub fn set_enable_flow_logs<T>(self, v: T) -> Self
pub fn set_enable_flow_logs<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_enable_flow_logs<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_enable_flow_logs<T>(self, v: Option<T>) -> Self
Sets or clears the value of enable_flow_logs.
§Example
let x = Subnetwork::new().set_or_clear_enable_flow_logs(Some(false));
let x = Subnetwork::new().set_or_clear_enable_flow_logs(None::<bool>);Sourcepub fn set_external_ipv_6_prefix<T>(self, v: T) -> Self
pub fn set_external_ipv_6_prefix<T>(self, v: T) -> Self
Sets the value of external_ipv_6_prefix.
§Example
let x = Subnetwork::new().set_external_ipv_6_prefix("example");Sourcepub fn set_or_clear_external_ipv_6_prefix<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_external_ipv_6_prefix<T>(self, v: Option<T>) -> Self
Sets or clears the value of external_ipv_6_prefix.
§Example
let x = Subnetwork::new().set_or_clear_external_ipv_6_prefix(Some("example"));
let x = Subnetwork::new().set_or_clear_external_ipv_6_prefix(None::<String>);Sourcepub fn set_fingerprint<T>(self, v: T) -> Self
pub fn set_fingerprint<T>(self, v: T) -> Self
Sets the value of fingerprint.
§Example
let x = Subnetwork::new().set_fingerprint(bytes::Bytes::from_static(b"example"));Sourcepub fn set_or_clear_fingerprint<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_fingerprint<T>(self, v: Option<T>) -> Self
Sets or clears the value of fingerprint.
§Example
let x = Subnetwork::new().set_or_clear_fingerprint(Some(bytes::Bytes::from_static(b"example")));
let x = Subnetwork::new().set_or_clear_fingerprint(None::<bytes::Bytes>);Sourcepub fn set_gateway_address<T>(self, v: T) -> Self
pub fn set_gateway_address<T>(self, v: T) -> Self
Sets the value of gateway_address.
§Example
let x = Subnetwork::new().set_gateway_address("example");Sourcepub fn set_or_clear_gateway_address<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_gateway_address<T>(self, v: Option<T>) -> Self
Sets or clears the value of gateway_address.
§Example
let x = Subnetwork::new().set_or_clear_gateway_address(Some("example"));
let x = Subnetwork::new().set_or_clear_gateway_address(None::<String>);Sourcepub fn set_or_clear_id<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_id<T>(self, v: Option<T>) -> Self
Sourcepub fn set_internal_ipv_6_prefix<T>(self, v: T) -> Self
pub fn set_internal_ipv_6_prefix<T>(self, v: T) -> Self
Sets the value of internal_ipv_6_prefix.
§Example
let x = Subnetwork::new().set_internal_ipv_6_prefix("example");Sourcepub fn set_or_clear_internal_ipv_6_prefix<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_internal_ipv_6_prefix<T>(self, v: Option<T>) -> Self
Sets or clears the value of internal_ipv_6_prefix.
§Example
let x = Subnetwork::new().set_or_clear_internal_ipv_6_prefix(Some("example"));
let x = Subnetwork::new().set_or_clear_internal_ipv_6_prefix(None::<String>);Sourcepub fn set_ip_cidr_range<T>(self, v: T) -> Self
pub fn set_ip_cidr_range<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_ip_cidr_range<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_ip_cidr_range<T>(self, v: Option<T>) -> Self
Sets or clears the value of ip_cidr_range.
§Example
let x = Subnetwork::new().set_or_clear_ip_cidr_range(Some("example"));
let x = Subnetwork::new().set_or_clear_ip_cidr_range(None::<String>);Sourcepub fn set_ip_collection<T>(self, v: T) -> Self
pub fn set_ip_collection<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_ip_collection<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_ip_collection<T>(self, v: Option<T>) -> Self
Sets or clears the value of ip_collection.
§Example
let x = Subnetwork::new().set_or_clear_ip_collection(Some("example"));
let x = Subnetwork::new().set_or_clear_ip_collection(None::<String>);Sourcepub fn set_ipv_6_access_type<T>(self, v: T) -> Selfwhere
T: Into<Ipv6AccessType>,
pub fn set_ipv_6_access_type<T>(self, v: T) -> Selfwhere
T: Into<Ipv6AccessType>,
Sets the value of ipv_6_access_type.
§Example
use google_cloud_compute_v1::model::subnetwork::Ipv6AccessType;
let x0 = Subnetwork::new().set_ipv_6_access_type(Ipv6AccessType::Internal);Sourcepub fn set_or_clear_ipv_6_access_type<T>(self, v: Option<T>) -> Selfwhere
T: Into<Ipv6AccessType>,
pub fn set_or_clear_ipv_6_access_type<T>(self, v: Option<T>) -> Selfwhere
T: Into<Ipv6AccessType>,
Sets or clears the value of ipv_6_access_type.
§Example
use google_cloud_compute_v1::model::subnetwork::Ipv6AccessType;
let x0 = Subnetwork::new().set_or_clear_ipv_6_access_type(Some(Ipv6AccessType::Internal));
let x_none = Subnetwork::new().set_or_clear_ipv_6_access_type(None::<Ipv6AccessType>);Sourcepub fn set_ipv_6_cidr_range<T>(self, v: T) -> Self
pub fn set_ipv_6_cidr_range<T>(self, v: T) -> Self
Sets the value of ipv_6_cidr_range.
§Example
let x = Subnetwork::new().set_ipv_6_cidr_range("example");Sourcepub fn set_or_clear_ipv_6_cidr_range<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_ipv_6_cidr_range<T>(self, v: Option<T>) -> Self
Sets or clears the value of ipv_6_cidr_range.
§Example
let x = Subnetwork::new().set_or_clear_ipv_6_cidr_range(Some("example"));
let x = Subnetwork::new().set_or_clear_ipv_6_cidr_range(None::<String>);Sourcepub fn set_ipv_6_gce_endpoint<T>(self, v: T) -> Selfwhere
T: Into<Ipv6GceEndpoint>,
pub fn set_ipv_6_gce_endpoint<T>(self, v: T) -> Selfwhere
T: Into<Ipv6GceEndpoint>,
Sets the value of ipv_6_gce_endpoint.
§Example
use google_cloud_compute_v1::model::subnetwork::Ipv6GceEndpoint;
let x0 = Subnetwork::new().set_ipv_6_gce_endpoint(Ipv6GceEndpoint::VmOnly);Sourcepub fn set_or_clear_ipv_6_gce_endpoint<T>(self, v: Option<T>) -> Selfwhere
T: Into<Ipv6GceEndpoint>,
pub fn set_or_clear_ipv_6_gce_endpoint<T>(self, v: Option<T>) -> Selfwhere
T: Into<Ipv6GceEndpoint>,
Sets or clears the value of ipv_6_gce_endpoint.
§Example
use google_cloud_compute_v1::model::subnetwork::Ipv6GceEndpoint;
let x0 = Subnetwork::new().set_or_clear_ipv_6_gce_endpoint(Some(Ipv6GceEndpoint::VmOnly));
let x_none = Subnetwork::new().set_or_clear_ipv_6_gce_endpoint(None::<Ipv6GceEndpoint>);Sourcepub fn set_or_clear_kind<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_kind<T>(self, v: Option<T>) -> Self
Sourcepub fn set_log_config<T>(self, v: T) -> Selfwhere
T: Into<SubnetworkLogConfig>,
pub fn set_log_config<T>(self, v: T) -> Selfwhere
T: Into<SubnetworkLogConfig>,
Sets the value of log_config.
§Example
use google_cloud_compute_v1::model::SubnetworkLogConfig;
let x = Subnetwork::new().set_log_config(SubnetworkLogConfig::default()/* use setters */);Sourcepub fn set_or_clear_log_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<SubnetworkLogConfig>,
pub fn set_or_clear_log_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<SubnetworkLogConfig>,
Sets or clears the value of log_config.
§Example
use google_cloud_compute_v1::model::SubnetworkLogConfig;
let x = Subnetwork::new().set_or_clear_log_config(Some(SubnetworkLogConfig::default()/* use setters */));
let x = Subnetwork::new().set_or_clear_log_config(None::<SubnetworkLogConfig>);Sourcepub fn set_or_clear_name<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_name<T>(self, v: Option<T>) -> Self
Sourcepub fn set_network<T>(self, v: T) -> Self
pub fn set_network<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_network<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_network<T>(self, v: Option<T>) -> Self
Sourcepub fn set_params<T>(self, v: T) -> Selfwhere
T: Into<SubnetworkParams>,
pub fn set_params<T>(self, v: T) -> Selfwhere
T: Into<SubnetworkParams>,
Sourcepub fn set_or_clear_params<T>(self, v: Option<T>) -> Selfwhere
T: Into<SubnetworkParams>,
pub fn set_or_clear_params<T>(self, v: Option<T>) -> Selfwhere
T: Into<SubnetworkParams>,
Sourcepub fn set_private_ip_google_access<T>(self, v: T) -> Self
pub fn set_private_ip_google_access<T>(self, v: T) -> Self
Sets the value of private_ip_google_access.
§Example
let x = Subnetwork::new().set_private_ip_google_access(true);Sourcepub fn set_or_clear_private_ip_google_access<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_private_ip_google_access<T>(self, v: Option<T>) -> Self
Sets or clears the value of private_ip_google_access.
§Example
let x = Subnetwork::new().set_or_clear_private_ip_google_access(Some(false));
let x = Subnetwork::new().set_or_clear_private_ip_google_access(None::<bool>);Sourcepub fn set_private_ipv_6_google_access<T>(self, v: T) -> Selfwhere
T: Into<PrivateIpv6GoogleAccess>,
pub fn set_private_ipv_6_google_access<T>(self, v: T) -> Selfwhere
T: Into<PrivateIpv6GoogleAccess>,
Sets the value of private_ipv_6_google_access.
§Example
use google_cloud_compute_v1::model::subnetwork::PrivateIpv6GoogleAccess;
let x0 = Subnetwork::new().set_private_ipv_6_google_access(PrivateIpv6GoogleAccess::EnableBidirectionalAccessToGoogle);
let x1 = Subnetwork::new().set_private_ipv_6_google_access(PrivateIpv6GoogleAccess::EnableOutboundVmAccessToGoogle);Sourcepub fn set_or_clear_private_ipv_6_google_access<T>(self, v: Option<T>) -> Selfwhere
T: Into<PrivateIpv6GoogleAccess>,
pub fn set_or_clear_private_ipv_6_google_access<T>(self, v: Option<T>) -> Selfwhere
T: Into<PrivateIpv6GoogleAccess>,
Sets or clears the value of private_ipv_6_google_access.
§Example
use google_cloud_compute_v1::model::subnetwork::PrivateIpv6GoogleAccess;
let x0 = Subnetwork::new().set_or_clear_private_ipv_6_google_access(Some(PrivateIpv6GoogleAccess::EnableBidirectionalAccessToGoogle));
let x1 = Subnetwork::new().set_or_clear_private_ipv_6_google_access(Some(PrivateIpv6GoogleAccess::EnableOutboundVmAccessToGoogle));
let x_none = Subnetwork::new().set_or_clear_private_ipv_6_google_access(None::<PrivateIpv6GoogleAccess>);Sourcepub fn set_purpose<T>(self, v: T) -> Self
pub fn set_purpose<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_purpose<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_purpose<T>(self, v: Option<T>) -> Self
Sets or clears the value of purpose.
§Example
use google_cloud_compute_v1::model::subnetwork::Purpose;
let x0 = Subnetwork::new().set_or_clear_purpose(Some(Purpose::InternalHttpsLoadBalancer));
let x1 = Subnetwork::new().set_or_clear_purpose(Some(Purpose::PeerMigration));
let x2 = Subnetwork::new().set_or_clear_purpose(Some(Purpose::Private));
let x_none = Subnetwork::new().set_or_clear_purpose(None::<Purpose>);Sourcepub fn set_region<T>(self, v: T) -> Self
pub fn set_region<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_region<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_region<T>(self, v: Option<T>) -> Self
Sourcepub fn set_reserved_internal_range<T>(self, v: T) -> Self
pub fn set_reserved_internal_range<T>(self, v: T) -> Self
Sets the value of reserved_internal_range.
§Example
let x = Subnetwork::new().set_reserved_internal_range("example");Sourcepub fn set_or_clear_reserved_internal_range<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_reserved_internal_range<T>(self, v: Option<T>) -> Self
Sets or clears the value of reserved_internal_range.
§Example
let x = Subnetwork::new().set_or_clear_reserved_internal_range(Some("example"));
let x = Subnetwork::new().set_or_clear_reserved_internal_range(None::<String>);Sourcepub fn set_or_clear_role<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_role<T>(self, v: Option<T>) -> Self
Sourcepub fn set_secondary_ip_ranges<T, V>(self, v: T) -> Self
pub fn set_secondary_ip_ranges<T, V>(self, v: T) -> Self
Sets the value of secondary_ip_ranges.
§Example
use google_cloud_compute_v1::model::SubnetworkSecondaryRange;
let x = Subnetwork::new()
.set_secondary_ip_ranges([
SubnetworkSecondaryRange::default()/* use setters */,
SubnetworkSecondaryRange::default()/* use (different) setters */,
]);Sourcepub fn set_self_link<T>(self, v: T) -> Self
pub fn set_self_link<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_self_link<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_self_link<T>(self, v: Option<T>) -> Self
Sourcepub fn set_stack_type<T>(self, v: T) -> Self
pub fn set_stack_type<T>(self, v: T) -> Self
Sets the value of stack_type.
§Example
use google_cloud_compute_v1::model::subnetwork::StackType;
let x0 = Subnetwork::new().set_stack_type(StackType::Ipv4Only);
let x1 = Subnetwork::new().set_stack_type(StackType::Ipv6Only);Sourcepub fn set_or_clear_stack_type<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_stack_type<T>(self, v: Option<T>) -> Self
Sets or clears the value of stack_type.
§Example
use google_cloud_compute_v1::model::subnetwork::StackType;
let x0 = Subnetwork::new().set_or_clear_stack_type(Some(StackType::Ipv4Only));
let x1 = Subnetwork::new().set_or_clear_stack_type(Some(StackType::Ipv6Only));
let x_none = Subnetwork::new().set_or_clear_stack_type(None::<StackType>);Sourcepub fn set_or_clear_state<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_state<T>(self, v: Option<T>) -> Self
Sourcepub fn set_system_reserved_external_ipv_6_ranges<T, V>(self, v: T) -> Self
pub fn set_system_reserved_external_ipv_6_ranges<T, V>(self, v: T) -> Self
Sets the value of system_reserved_external_ipv_6_ranges.
§Example
let x = Subnetwork::new().set_system_reserved_external_ipv_6_ranges(["a", "b", "c"]);Sourcepub fn set_system_reserved_internal_ipv_6_ranges<T, V>(self, v: T) -> Self
pub fn set_system_reserved_internal_ipv_6_ranges<T, V>(self, v: T) -> Self
Sets the value of system_reserved_internal_ipv_6_ranges.
§Example
let x = Subnetwork::new().set_system_reserved_internal_ipv_6_ranges(["a", "b", "c"]);Sourcepub fn set_utilization_details<T>(self, v: T) -> Selfwhere
T: Into<SubnetworkUtilizationDetails>,
pub fn set_utilization_details<T>(self, v: T) -> Selfwhere
T: Into<SubnetworkUtilizationDetails>,
Sets the value of utilization_details.
§Example
use google_cloud_compute_v1::model::SubnetworkUtilizationDetails;
let x = Subnetwork::new().set_utilization_details(SubnetworkUtilizationDetails::default()/* use setters */);Sourcepub fn set_or_clear_utilization_details<T>(self, v: Option<T>) -> Selfwhere
T: Into<SubnetworkUtilizationDetails>,
pub fn set_or_clear_utilization_details<T>(self, v: Option<T>) -> Selfwhere
T: Into<SubnetworkUtilizationDetails>,
Sets or clears the value of utilization_details.
§Example
use google_cloud_compute_v1::model::SubnetworkUtilizationDetails;
let x = Subnetwork::new().set_or_clear_utilization_details(Some(SubnetworkUtilizationDetails::default()/* use setters */));
let x = Subnetwork::new().set_or_clear_utilization_details(None::<SubnetworkUtilizationDetails>);Trait Implementations§
Source§impl Clone for Subnetwork
impl Clone for Subnetwork
Source§fn clone(&self) -> Subnetwork
fn clone(&self) -> Subnetwork
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more