- 1.57.0 (latest)
- 1.56.0
- 1.55.0
- 1.54.0
- 1.53.0
- 1.52.0
- 1.51.0
- 1.50.0
- 1.49.0
- 1.47.0
- 1.46.0
- 1.45.0
- 1.44.0
- 1.43.0
- 1.42.0
- 1.41.0
- 1.40.0
- 1.39.0
- 1.38.0
- 1.37.0
- 1.34.0
- 1.33.0
- 1.32.0
- 1.31.0
- 1.30.0
- 1.29.0
- 1.28.0
- 1.27.0
- 1.26.0
- 1.25.0
- 1.24.0
- 1.23.0
- 1.22.0
- 1.21.0
- 1.20.0
- 1.19.0
- 1.18.0
- 1.17.0
- 1.16.0
- 1.15.0
- 1.14.0
- 1.13.0
- 1.12.1
- 1.11.0
- 1.9.1
- 1.8.1
- 1.7.2
- 1.6.0-beta
public static final class RouterNat.Builder extends GeneratedMessageV3.Builder<RouterNat.Builder> implements RouterNatOrBuilder
Represents a Nat resource. It enables the VMs within the specified subnetworks to access Internet without external IP addresses. It specifies a list of subnetworks (and the ranges within) that want to use NAT. Customers can also provide the external IPs that would be used for NAT. GCP would auto-allocate ephemeral IPs if no external IPs are provided.
Protobuf type google.cloud.compute.v1.RouterNat
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > RouterNat.BuilderImplements
RouterNatOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns | |
---|---|
Type | Description |
Descriptor |
Methods
addAllDrainNatIps(Iterable<String> values)
public RouterNat.Builder addAllDrainNatIps(Iterable<String> values)
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Parameter | |
---|---|
Name | Description |
values | Iterable<String> The drainNatIps to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addAllEndpointTypes(Iterable<String> values)
public RouterNat.Builder addAllEndpointTypes(Iterable<String> values)
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Parameter | |
---|---|
Name | Description |
values | Iterable<String> The endpointTypes to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addAllNatIps(Iterable<String> values)
public RouterNat.Builder addAllNatIps(Iterable<String> values)
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Parameter | |
---|---|
Name | Description |
values | Iterable<String> The natIps to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addAllRules(Iterable<? extends RouterNatRule> values)
public RouterNat.Builder addAllRules(Iterable<? extends RouterNatRule> values)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
values | Iterable<? extends com.google.cloud.compute.v1.RouterNatRule> |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addAllSubnetworks(Iterable<? extends RouterNatSubnetworkToNat> values)
public RouterNat.Builder addAllSubnetworks(Iterable<? extends RouterNatSubnetworkToNat> values)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
values | Iterable<? extends com.google.cloud.compute.v1.RouterNatSubnetworkToNat> |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addDrainNatIps(String value)
public RouterNat.Builder addDrainNatIps(String value)
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Parameter | |
---|---|
Name | Description |
value | String The drainNatIps to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addDrainNatIpsBytes(ByteString value)
public RouterNat.Builder addDrainNatIpsBytes(ByteString value)
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes of the drainNatIps to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addEndpointTypes(String value)
public RouterNat.Builder addEndpointTypes(String value)
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Parameter | |
---|---|
Name | Description |
value | String The endpointTypes to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addEndpointTypesBytes(ByteString value)
public RouterNat.Builder addEndpointTypesBytes(ByteString value)
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes of the endpointTypes to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addNatIps(String value)
public RouterNat.Builder addNatIps(String value)
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Parameter | |
---|---|
Name | Description |
value | String The natIps to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addNatIpsBytes(ByteString value)
public RouterNat.Builder addNatIpsBytes(ByteString value)
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes of the natIps to add. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public RouterNat.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters | |
---|---|
Name | Description |
field | FieldDescriptor |
value | Object |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addRules(RouterNatRule value)
public RouterNat.Builder addRules(RouterNatRule value)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
value | RouterNatRule |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addRules(RouterNatRule.Builder builderForValue)
public RouterNat.Builder addRules(RouterNatRule.Builder builderForValue)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
builderForValue | RouterNatRule.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addRules(int index, RouterNatRule value)
public RouterNat.Builder addRules(int index, RouterNatRule value)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameters | |
---|---|
Name | Description |
index | int |
value | RouterNatRule |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addRules(int index, RouterNatRule.Builder builderForValue)
public RouterNat.Builder addRules(int index, RouterNatRule.Builder builderForValue)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | RouterNatRule.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addRulesBuilder()
public RouterNatRule.Builder addRulesBuilder()
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Returns | |
---|---|
Type | Description |
RouterNatRule.Builder |
addRulesBuilder(int index)
public RouterNatRule.Builder addRulesBuilder(int index)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatRule.Builder |
addSubnetworks(RouterNatSubnetworkToNat value)
public RouterNat.Builder addSubnetworks(RouterNatSubnetworkToNat value)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
value | RouterNatSubnetworkToNat |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addSubnetworks(RouterNatSubnetworkToNat.Builder builderForValue)
public RouterNat.Builder addSubnetworks(RouterNatSubnetworkToNat.Builder builderForValue)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
builderForValue | RouterNatSubnetworkToNat.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addSubnetworks(int index, RouterNatSubnetworkToNat value)
public RouterNat.Builder addSubnetworks(int index, RouterNatSubnetworkToNat value)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameters | |
---|---|
Name | Description |
index | int |
value | RouterNatSubnetworkToNat |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addSubnetworks(int index, RouterNatSubnetworkToNat.Builder builderForValue)
public RouterNat.Builder addSubnetworks(int index, RouterNatSubnetworkToNat.Builder builderForValue)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | RouterNatSubnetworkToNat.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
addSubnetworksBuilder()
public RouterNatSubnetworkToNat.Builder addSubnetworksBuilder()
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Returns | |
---|---|
Type | Description |
RouterNatSubnetworkToNat.Builder |
addSubnetworksBuilder(int index)
public RouterNatSubnetworkToNat.Builder addSubnetworksBuilder(int index)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatSubnetworkToNat.Builder |
build()
public RouterNat build()
Returns | |
---|---|
Type | Description |
RouterNat |
buildPartial()
public RouterNat buildPartial()
Returns | |
---|---|
Type | Description |
RouterNat |
clear()
public RouterNat.Builder clear()
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
clearDrainNatIps()
public RouterNat.Builder clearDrainNatIps()
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearEnableDynamicPortAllocation()
public RouterNat.Builder clearEnableDynamicPortAllocation()
Enable Dynamic Port Allocation. If not specified, it is disabled by default. If set to true, - Dynamic Port Allocation will be enabled on this NAT config. - enableEndpointIndependentMapping cannot be set to true. - If minPorts is set, minPortsPerVm must be set to a power of two greater than or equal to 32. If minPortsPerVm is not set, a minimum of 32 ports will be allocated to a VM from this NAT config.
optional bool enable_dynamic_port_allocation = 532106402;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearEnableEndpointIndependentMapping()
public RouterNat.Builder clearEnableEndpointIndependentMapping()
optional bool enable_endpoint_independent_mapping = 259441819;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearEndpointTypes()
public RouterNat.Builder clearEndpointTypes()
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearField(Descriptors.FieldDescriptor field)
public RouterNat.Builder clearField(Descriptors.FieldDescriptor field)
Parameter | |
---|---|
Name | Description |
field | FieldDescriptor |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
clearIcmpIdleTimeoutSec()
public RouterNat.Builder clearIcmpIdleTimeoutSec()
Timeout (in seconds) for ICMP connections. Defaults to 30s if not set.
optional int32 icmp_idle_timeout_sec = 3647562;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearLogConfig()
public RouterNat.Builder clearLogConfig()
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
clearMaxPortsPerVm()
public RouterNat.Builder clearMaxPortsPerVm()
Maximum number of ports allocated to a VM from this NAT config when Dynamic Port Allocation is enabled. If Dynamic Port Allocation is not enabled, this field has no effect. If Dynamic Port Allocation is enabled, and this field is set, it must be set to a power of two greater than minPortsPerVm, or 64 if minPortsPerVm is not set. If Dynamic Port Allocation is enabled and this field is not set, a maximum of 65536 ports will be allocated to a VM from this NAT config.
optional int32 max_ports_per_vm = 250062049;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearMinPortsPerVm()
public RouterNat.Builder clearMinPortsPerVm()
Minimum number of ports allocated to a VM from this NAT config. If not set, a default number of ports is allocated to a VM. This is rounded up to the nearest power of 2. For example, if the value of this field is 50, at least 64 ports are allocated to a VM.
optional int32 min_ports_per_vm = 186193587;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearName()
public RouterNat.Builder clearName()
Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035.
optional string name = 3373707;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearNatIpAllocateOption()
public RouterNat.Builder clearNatIpAllocateOption()
Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. Check the NatIpAllocateOption enum for the list of possible values.
optional string nat_ip_allocate_option = 429726845;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearNatIps()
public RouterNat.Builder clearNatIps()
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public RouterNat.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter | |
---|---|
Name | Description |
oneof | OneofDescriptor |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
clearRules()
public RouterNat.Builder clearRules()
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
clearSourceSubnetworkIpRangesToNat()
public RouterNat.Builder clearSourceSubnetworkIpRangesToNat()
Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. Check the SourceSubnetworkIpRangesToNat enum for the list of possible values.
optional string source_subnetwork_ip_ranges_to_nat = 252213211;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearSubnetworks()
public RouterNat.Builder clearSubnetworks()
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
clearTcpEstablishedIdleTimeoutSec()
public RouterNat.Builder clearTcpEstablishedIdleTimeoutSec()
Timeout (in seconds) for TCP established connections. Defaults to 1200s if not set.
optional int32 tcp_established_idle_timeout_sec = 223098349;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearTcpTimeWaitTimeoutSec()
public RouterNat.Builder clearTcpTimeWaitTimeoutSec()
Timeout (in seconds) for TCP connections that are in TIME_WAIT state. Defaults to 120s if not set.
optional int32 tcp_time_wait_timeout_sec = 513596925;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearTcpTransitoryIdleTimeoutSec()
public RouterNat.Builder clearTcpTransitoryIdleTimeoutSec()
Timeout (in seconds) for TCP transitory connections. Defaults to 30s if not set.
optional int32 tcp_transitory_idle_timeout_sec = 205028774;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clearUdpIdleTimeoutSec()
public RouterNat.Builder clearUdpIdleTimeoutSec()
Timeout (in seconds) for UDP connections. Defaults to 30s if not set.
optional int32 udp_idle_timeout_sec = 64919878;
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
clone()
public RouterNat.Builder clone()
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
getDefaultInstanceForType()
public RouterNat getDefaultInstanceForType()
Returns | |
---|---|
Type | Description |
RouterNat |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns | |
---|---|
Type | Description |
Descriptor |
getDrainNatIps(int index)
public String getDrainNatIps(int index)
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Parameter | |
---|---|
Name | Description |
index | int The index of the element to return. |
Returns | |
---|---|
Type | Description |
String | The drainNatIps at the given index. |
getDrainNatIpsBytes(int index)
public ByteString getDrainNatIpsBytes(int index)
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Parameter | |
---|---|
Name | Description |
index | int The index of the value to return. |
Returns | |
---|---|
Type | Description |
ByteString | The bytes of the drainNatIps at the given index. |
getDrainNatIpsCount()
public int getDrainNatIpsCount()
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Returns | |
---|---|
Type | Description |
int | The count of drainNatIps. |
getDrainNatIpsList()
public ProtocolStringList getDrainNatIpsList()
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Returns | |
---|---|
Type | Description |
ProtocolStringList | A list containing the drainNatIps. |
getEnableDynamicPortAllocation()
public boolean getEnableDynamicPortAllocation()
Enable Dynamic Port Allocation. If not specified, it is disabled by default. If set to true, - Dynamic Port Allocation will be enabled on this NAT config. - enableEndpointIndependentMapping cannot be set to true. - If minPorts is set, minPortsPerVm must be set to a power of two greater than or equal to 32. If minPortsPerVm is not set, a minimum of 32 ports will be allocated to a VM from this NAT config.
optional bool enable_dynamic_port_allocation = 532106402;
Returns | |
---|---|
Type | Description |
boolean | The enableDynamicPortAllocation. |
getEnableEndpointIndependentMapping()
public boolean getEnableEndpointIndependentMapping()
optional bool enable_endpoint_independent_mapping = 259441819;
Returns | |
---|---|
Type | Description |
boolean | The enableEndpointIndependentMapping. |
getEndpointTypes(int index)
public String getEndpointTypes(int index)
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Parameter | |
---|---|
Name | Description |
index | int The index of the element to return. |
Returns | |
---|---|
Type | Description |
String | The endpointTypes at the given index. |
getEndpointTypesBytes(int index)
public ByteString getEndpointTypesBytes(int index)
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Parameter | |
---|---|
Name | Description |
index | int The index of the value to return. |
Returns | |
---|---|
Type | Description |
ByteString | The bytes of the endpointTypes at the given index. |
getEndpointTypesCount()
public int getEndpointTypesCount()
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Returns | |
---|---|
Type | Description |
int | The count of endpointTypes. |
getEndpointTypesList()
public ProtocolStringList getEndpointTypesList()
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Returns | |
---|---|
Type | Description |
ProtocolStringList | A list containing the endpointTypes. |
getIcmpIdleTimeoutSec()
public int getIcmpIdleTimeoutSec()
Timeout (in seconds) for ICMP connections. Defaults to 30s if not set.
optional int32 icmp_idle_timeout_sec = 3647562;
Returns | |
---|---|
Type | Description |
int | The icmpIdleTimeoutSec. |
getLogConfig()
public RouterNatLogConfig getLogConfig()
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Returns | |
---|---|
Type | Description |
RouterNatLogConfig | The logConfig. |
getLogConfigBuilder()
public RouterNatLogConfig.Builder getLogConfigBuilder()
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Returns | |
---|---|
Type | Description |
RouterNatLogConfig.Builder |
getLogConfigOrBuilder()
public RouterNatLogConfigOrBuilder getLogConfigOrBuilder()
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Returns | |
---|---|
Type | Description |
RouterNatLogConfigOrBuilder |
getMaxPortsPerVm()
public int getMaxPortsPerVm()
Maximum number of ports allocated to a VM from this NAT config when Dynamic Port Allocation is enabled. If Dynamic Port Allocation is not enabled, this field has no effect. If Dynamic Port Allocation is enabled, and this field is set, it must be set to a power of two greater than minPortsPerVm, or 64 if minPortsPerVm is not set. If Dynamic Port Allocation is enabled and this field is not set, a maximum of 65536 ports will be allocated to a VM from this NAT config.
optional int32 max_ports_per_vm = 250062049;
Returns | |
---|---|
Type | Description |
int | The maxPortsPerVm. |
getMinPortsPerVm()
public int getMinPortsPerVm()
Minimum number of ports allocated to a VM from this NAT config. If not set, a default number of ports is allocated to a VM. This is rounded up to the nearest power of 2. For example, if the value of this field is 50, at least 64 ports are allocated to a VM.
optional int32 min_ports_per_vm = 186193587;
Returns | |
---|---|
Type | Description |
int | The minPortsPerVm. |
getName()
public String getName()
Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035.
optional string name = 3373707;
Returns | |
---|---|
Type | Description |
String | The name. |
getNameBytes()
public ByteString getNameBytes()
Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035.
optional string name = 3373707;
Returns | |
---|---|
Type | Description |
ByteString | The bytes for name. |
getNatIpAllocateOption()
public String getNatIpAllocateOption()
Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. Check the NatIpAllocateOption enum for the list of possible values.
optional string nat_ip_allocate_option = 429726845;
Returns | |
---|---|
Type | Description |
String | The natIpAllocateOption. |
getNatIpAllocateOptionBytes()
public ByteString getNatIpAllocateOptionBytes()
Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. Check the NatIpAllocateOption enum for the list of possible values.
optional string nat_ip_allocate_option = 429726845;
Returns | |
---|---|
Type | Description |
ByteString | The bytes for natIpAllocateOption. |
getNatIps(int index)
public String getNatIps(int index)
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Parameter | |
---|---|
Name | Description |
index | int The index of the element to return. |
Returns | |
---|---|
Type | Description |
String | The natIps at the given index. |
getNatIpsBytes(int index)
public ByteString getNatIpsBytes(int index)
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Parameter | |
---|---|
Name | Description |
index | int The index of the value to return. |
Returns | |
---|---|
Type | Description |
ByteString | The bytes of the natIps at the given index. |
getNatIpsCount()
public int getNatIpsCount()
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Returns | |
---|---|
Type | Description |
int | The count of natIps. |
getNatIpsList()
public ProtocolStringList getNatIpsList()
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Returns | |
---|---|
Type | Description |
ProtocolStringList | A list containing the natIps. |
getRules(int index)
public RouterNatRule getRules(int index)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatRule |
getRulesBuilder(int index)
public RouterNatRule.Builder getRulesBuilder(int index)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatRule.Builder |
getRulesBuilderList()
public List<RouterNatRule.Builder> getRulesBuilderList()
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Returns | |
---|---|
Type | Description |
List<Builder> |
getRulesCount()
public int getRulesCount()
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Returns | |
---|---|
Type | Description |
int |
getRulesList()
public List<RouterNatRule> getRulesList()
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Returns | |
---|---|
Type | Description |
List<RouterNatRule> |
getRulesOrBuilder(int index)
public RouterNatRuleOrBuilder getRulesOrBuilder(int index)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatRuleOrBuilder |
getRulesOrBuilderList()
public List<? extends RouterNatRuleOrBuilder> getRulesOrBuilderList()
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Returns | |
---|---|
Type | Description |
List<? extends com.google.cloud.compute.v1.RouterNatRuleOrBuilder> |
getSourceSubnetworkIpRangesToNat()
public String getSourceSubnetworkIpRangesToNat()
Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. Check the SourceSubnetworkIpRangesToNat enum for the list of possible values.
optional string source_subnetwork_ip_ranges_to_nat = 252213211;
Returns | |
---|---|
Type | Description |
String | The sourceSubnetworkIpRangesToNat. |
getSourceSubnetworkIpRangesToNatBytes()
public ByteString getSourceSubnetworkIpRangesToNatBytes()
Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. Check the SourceSubnetworkIpRangesToNat enum for the list of possible values.
optional string source_subnetwork_ip_ranges_to_nat = 252213211;
Returns | |
---|---|
Type | Description |
ByteString | The bytes for sourceSubnetworkIpRangesToNat. |
getSubnetworks(int index)
public RouterNatSubnetworkToNat getSubnetworks(int index)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatSubnetworkToNat |
getSubnetworksBuilder(int index)
public RouterNatSubnetworkToNat.Builder getSubnetworksBuilder(int index)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatSubnetworkToNat.Builder |
getSubnetworksBuilderList()
public List<RouterNatSubnetworkToNat.Builder> getSubnetworksBuilderList()
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Returns | |
---|---|
Type | Description |
List<Builder> |
getSubnetworksCount()
public int getSubnetworksCount()
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Returns | |
---|---|
Type | Description |
int |
getSubnetworksList()
public List<RouterNatSubnetworkToNat> getSubnetworksList()
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Returns | |
---|---|
Type | Description |
List<RouterNatSubnetworkToNat> |
getSubnetworksOrBuilder(int index)
public RouterNatSubnetworkToNatOrBuilder getSubnetworksOrBuilder(int index)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNatSubnetworkToNatOrBuilder |
getSubnetworksOrBuilderList()
public List<? extends RouterNatSubnetworkToNatOrBuilder> getSubnetworksOrBuilderList()
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Returns | |
---|---|
Type | Description |
List<? extends com.google.cloud.compute.v1.RouterNatSubnetworkToNatOrBuilder> |
getTcpEstablishedIdleTimeoutSec()
public int getTcpEstablishedIdleTimeoutSec()
Timeout (in seconds) for TCP established connections. Defaults to 1200s if not set.
optional int32 tcp_established_idle_timeout_sec = 223098349;
Returns | |
---|---|
Type | Description |
int | The tcpEstablishedIdleTimeoutSec. |
getTcpTimeWaitTimeoutSec()
public int getTcpTimeWaitTimeoutSec()
Timeout (in seconds) for TCP connections that are in TIME_WAIT state. Defaults to 120s if not set.
optional int32 tcp_time_wait_timeout_sec = 513596925;
Returns | |
---|---|
Type | Description |
int | The tcpTimeWaitTimeoutSec. |
getTcpTransitoryIdleTimeoutSec()
public int getTcpTransitoryIdleTimeoutSec()
Timeout (in seconds) for TCP transitory connections. Defaults to 30s if not set.
optional int32 tcp_transitory_idle_timeout_sec = 205028774;
Returns | |
---|---|
Type | Description |
int | The tcpTransitoryIdleTimeoutSec. |
getUdpIdleTimeoutSec()
public int getUdpIdleTimeoutSec()
Timeout (in seconds) for UDP connections. Defaults to 30s if not set.
optional int32 udp_idle_timeout_sec = 64919878;
Returns | |
---|---|
Type | Description |
int | The udpIdleTimeoutSec. |
hasEnableDynamicPortAllocation()
public boolean hasEnableDynamicPortAllocation()
Enable Dynamic Port Allocation. If not specified, it is disabled by default. If set to true, - Dynamic Port Allocation will be enabled on this NAT config. - enableEndpointIndependentMapping cannot be set to true. - If minPorts is set, minPortsPerVm must be set to a power of two greater than or equal to 32. If minPortsPerVm is not set, a minimum of 32 ports will be allocated to a VM from this NAT config.
optional bool enable_dynamic_port_allocation = 532106402;
Returns | |
---|---|
Type | Description |
boolean | Whether the enableDynamicPortAllocation field is set. |
hasEnableEndpointIndependentMapping()
public boolean hasEnableEndpointIndependentMapping()
optional bool enable_endpoint_independent_mapping = 259441819;
Returns | |
---|---|
Type | Description |
boolean | Whether the enableEndpointIndependentMapping field is set. |
hasIcmpIdleTimeoutSec()
public boolean hasIcmpIdleTimeoutSec()
Timeout (in seconds) for ICMP connections. Defaults to 30s if not set.
optional int32 icmp_idle_timeout_sec = 3647562;
Returns | |
---|---|
Type | Description |
boolean | Whether the icmpIdleTimeoutSec field is set. |
hasLogConfig()
public boolean hasLogConfig()
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Returns | |
---|---|
Type | Description |
boolean | Whether the logConfig field is set. |
hasMaxPortsPerVm()
public boolean hasMaxPortsPerVm()
Maximum number of ports allocated to a VM from this NAT config when Dynamic Port Allocation is enabled. If Dynamic Port Allocation is not enabled, this field has no effect. If Dynamic Port Allocation is enabled, and this field is set, it must be set to a power of two greater than minPortsPerVm, or 64 if minPortsPerVm is not set. If Dynamic Port Allocation is enabled and this field is not set, a maximum of 65536 ports will be allocated to a VM from this NAT config.
optional int32 max_ports_per_vm = 250062049;
Returns | |
---|---|
Type | Description |
boolean | Whether the maxPortsPerVm field is set. |
hasMinPortsPerVm()
public boolean hasMinPortsPerVm()
Minimum number of ports allocated to a VM from this NAT config. If not set, a default number of ports is allocated to a VM. This is rounded up to the nearest power of 2. For example, if the value of this field is 50, at least 64 ports are allocated to a VM.
optional int32 min_ports_per_vm = 186193587;
Returns | |
---|---|
Type | Description |
boolean | Whether the minPortsPerVm field is set. |
hasName()
public boolean hasName()
Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035.
optional string name = 3373707;
Returns | |
---|---|
Type | Description |
boolean | Whether the name field is set. |
hasNatIpAllocateOption()
public boolean hasNatIpAllocateOption()
Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. Check the NatIpAllocateOption enum for the list of possible values.
optional string nat_ip_allocate_option = 429726845;
Returns | |
---|---|
Type | Description |
boolean | Whether the natIpAllocateOption field is set. |
hasSourceSubnetworkIpRangesToNat()
public boolean hasSourceSubnetworkIpRangesToNat()
Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. Check the SourceSubnetworkIpRangesToNat enum for the list of possible values.
optional string source_subnetwork_ip_ranges_to_nat = 252213211;
Returns | |
---|---|
Type | Description |
boolean | Whether the sourceSubnetworkIpRangesToNat field is set. |
hasTcpEstablishedIdleTimeoutSec()
public boolean hasTcpEstablishedIdleTimeoutSec()
Timeout (in seconds) for TCP established connections. Defaults to 1200s if not set.
optional int32 tcp_established_idle_timeout_sec = 223098349;
Returns | |
---|---|
Type | Description |
boolean | Whether the tcpEstablishedIdleTimeoutSec field is set. |
hasTcpTimeWaitTimeoutSec()
public boolean hasTcpTimeWaitTimeoutSec()
Timeout (in seconds) for TCP connections that are in TIME_WAIT state. Defaults to 120s if not set.
optional int32 tcp_time_wait_timeout_sec = 513596925;
Returns | |
---|---|
Type | Description |
boolean | Whether the tcpTimeWaitTimeoutSec field is set. |
hasTcpTransitoryIdleTimeoutSec()
public boolean hasTcpTransitoryIdleTimeoutSec()
Timeout (in seconds) for TCP transitory connections. Defaults to 30s if not set.
optional int32 tcp_transitory_idle_timeout_sec = 205028774;
Returns | |
---|---|
Type | Description |
boolean | Whether the tcpTransitoryIdleTimeoutSec field is set. |
hasUdpIdleTimeoutSec()
public boolean hasUdpIdleTimeoutSec()
Timeout (in seconds) for UDP connections. Defaults to 30s if not set.
optional int32 udp_idle_timeout_sec = 64919878;
Returns | |
---|---|
Type | Description |
boolean | Whether the udpIdleTimeoutSec field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns | |
---|---|
Type | Description |
FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Returns | |
---|---|
Type | Description |
boolean |
mergeFrom(RouterNat other)
public RouterNat.Builder mergeFrom(RouterNat other)
Parameter | |
---|---|
Name | Description |
other | RouterNat |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public RouterNat.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters | |
---|---|
Name | Description |
input | CodedInputStream |
extensionRegistry | ExtensionRegistryLite |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
Exceptions | |
---|---|
Type | Description |
IOException |
mergeFrom(Message other)
public RouterNat.Builder mergeFrom(Message other)
Parameter | |
---|---|
Name | Description |
other | Message |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
mergeLogConfig(RouterNatLogConfig value)
public RouterNat.Builder mergeLogConfig(RouterNatLogConfig value)
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Parameter | |
---|---|
Name | Description |
value | RouterNatLogConfig |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final RouterNat.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields | UnknownFieldSet |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
removeRules(int index)
public RouterNat.Builder removeRules(int index)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
removeSubnetworks(int index)
public RouterNat.Builder removeSubnetworks(int index)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameter | |
---|---|
Name | Description |
index | int |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setDrainNatIps(int index, String value)
public RouterNat.Builder setDrainNatIps(int index, String value)
A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only.
repeated string drain_nat_ips = 504078535;
Parameters | |
---|---|
Name | Description |
index | int The index to set the value at. |
value | String The drainNatIps to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setEnableDynamicPortAllocation(boolean value)
public RouterNat.Builder setEnableDynamicPortAllocation(boolean value)
Enable Dynamic Port Allocation. If not specified, it is disabled by default. If set to true, - Dynamic Port Allocation will be enabled on this NAT config. - enableEndpointIndependentMapping cannot be set to true. - If minPorts is set, minPortsPerVm must be set to a power of two greater than or equal to 32. If minPortsPerVm is not set, a minimum of 32 ports will be allocated to a VM from this NAT config.
optional bool enable_dynamic_port_allocation = 532106402;
Parameter | |
---|---|
Name | Description |
value | boolean The enableDynamicPortAllocation to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setEnableEndpointIndependentMapping(boolean value)
public RouterNat.Builder setEnableEndpointIndependentMapping(boolean value)
optional bool enable_endpoint_independent_mapping = 259441819;
Parameter | |
---|---|
Name | Description |
value | boolean The enableEndpointIndependentMapping to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setEndpointTypes(int index, String value)
public RouterNat.Builder setEndpointTypes(int index, String value)
List of NAT-ted endpoint types supported by the Nat Gateway. If the list is empty, then it will be equivalent to include ENDPOINT_TYPE_VM Check the EndpointTypes enum for the list of possible values.
repeated string endpoint_types = 502633807;
Parameters | |
---|---|
Name | Description |
index | int The index to set the value at. |
value | String The endpointTypes to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setField(Descriptors.FieldDescriptor field, Object value)
public RouterNat.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters | |
---|---|
Name | Description |
field | FieldDescriptor |
value | Object |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setIcmpIdleTimeoutSec(int value)
public RouterNat.Builder setIcmpIdleTimeoutSec(int value)
Timeout (in seconds) for ICMP connections. Defaults to 30s if not set.
optional int32 icmp_idle_timeout_sec = 3647562;
Parameter | |
---|---|
Name | Description |
value | int The icmpIdleTimeoutSec to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setLogConfig(RouterNatLogConfig value)
public RouterNat.Builder setLogConfig(RouterNatLogConfig value)
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Parameter | |
---|---|
Name | Description |
value | RouterNatLogConfig |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setLogConfig(RouterNatLogConfig.Builder builderForValue)
public RouterNat.Builder setLogConfig(RouterNatLogConfig.Builder builderForValue)
Configure logging on this NAT.
optional .google.cloud.compute.v1.RouterNatLogConfig log_config = 351299741;
Parameter | |
---|---|
Name | Description |
builderForValue | RouterNatLogConfig.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setMaxPortsPerVm(int value)
public RouterNat.Builder setMaxPortsPerVm(int value)
Maximum number of ports allocated to a VM from this NAT config when Dynamic Port Allocation is enabled. If Dynamic Port Allocation is not enabled, this field has no effect. If Dynamic Port Allocation is enabled, and this field is set, it must be set to a power of two greater than minPortsPerVm, or 64 if minPortsPerVm is not set. If Dynamic Port Allocation is enabled and this field is not set, a maximum of 65536 ports will be allocated to a VM from this NAT config.
optional int32 max_ports_per_vm = 250062049;
Parameter | |
---|---|
Name | Description |
value | int The maxPortsPerVm to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setMinPortsPerVm(int value)
public RouterNat.Builder setMinPortsPerVm(int value)
Minimum number of ports allocated to a VM from this NAT config. If not set, a default number of ports is allocated to a VM. This is rounded up to the nearest power of 2. For example, if the value of this field is 50, at least 64 ports are allocated to a VM.
optional int32 min_ports_per_vm = 186193587;
Parameter | |
---|---|
Name | Description |
value | int The minPortsPerVm to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setName(String value)
public RouterNat.Builder setName(String value)
Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035.
optional string name = 3373707;
Parameter | |
---|---|
Name | Description |
value | String The name to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setNameBytes(ByteString value)
public RouterNat.Builder setNameBytes(ByteString value)
Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035.
optional string name = 3373707;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for name to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setNatIpAllocateOption(String value)
public RouterNat.Builder setNatIpAllocateOption(String value)
Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. Check the NatIpAllocateOption enum for the list of possible values.
optional string nat_ip_allocate_option = 429726845;
Parameter | |
---|---|
Name | Description |
value | String The natIpAllocateOption to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setNatIpAllocateOptionBytes(ByteString value)
public RouterNat.Builder setNatIpAllocateOptionBytes(ByteString value)
Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. Check the NatIpAllocateOption enum for the list of possible values.
optional string nat_ip_allocate_option = 429726845;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for natIpAllocateOption to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setNatIps(int index, String value)
public RouterNat.Builder setNatIps(int index, String value)
A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project.
repeated string nat_ips = 117635086;
Parameters | |
---|---|
Name | Description |
index | int The index to set the value at. |
value | String The natIps to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public RouterNat.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters | |
---|---|
Name | Description |
field | FieldDescriptor |
index | int |
value | Object |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setRules(int index, RouterNatRule value)
public RouterNat.Builder setRules(int index, RouterNatRule value)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameters | |
---|---|
Name | Description |
index | int |
value | RouterNatRule |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setRules(int index, RouterNatRule.Builder builderForValue)
public RouterNat.Builder setRules(int index, RouterNatRule.Builder builderForValue)
A list of rules associated with this NAT.
repeated .google.cloud.compute.v1.RouterNatRule rules = 108873975;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | RouterNatRule.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setSourceSubnetworkIpRangesToNat(String value)
public RouterNat.Builder setSourceSubnetworkIpRangesToNat(String value)
Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. Check the SourceSubnetworkIpRangesToNat enum for the list of possible values.
optional string source_subnetwork_ip_ranges_to_nat = 252213211;
Parameter | |
---|---|
Name | Description |
value | String The sourceSubnetworkIpRangesToNat to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setSourceSubnetworkIpRangesToNatBytes(ByteString value)
public RouterNat.Builder setSourceSubnetworkIpRangesToNatBytes(ByteString value)
Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. Check the SourceSubnetworkIpRangesToNat enum for the list of possible values.
optional string source_subnetwork_ip_ranges_to_nat = 252213211;
Parameter | |
---|---|
Name | Description |
value | ByteString The bytes for sourceSubnetworkIpRangesToNat to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setSubnetworks(int index, RouterNatSubnetworkToNat value)
public RouterNat.Builder setSubnetworks(int index, RouterNatSubnetworkToNat value)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameters | |
---|---|
Name | Description |
index | int |
value | RouterNatSubnetworkToNat |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setSubnetworks(int index, RouterNatSubnetworkToNat.Builder builderForValue)
public RouterNat.Builder setSubnetworks(int index, RouterNatSubnetworkToNat.Builder builderForValue)
A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above.
repeated .google.cloud.compute.v1.RouterNatSubnetworkToNat subnetworks = 415853125;
Parameters | |
---|---|
Name | Description |
index | int |
builderForValue | RouterNatSubnetworkToNat.Builder |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |
setTcpEstablishedIdleTimeoutSec(int value)
public RouterNat.Builder setTcpEstablishedIdleTimeoutSec(int value)
Timeout (in seconds) for TCP established connections. Defaults to 1200s if not set.
optional int32 tcp_established_idle_timeout_sec = 223098349;
Parameter | |
---|---|
Name | Description |
value | int The tcpEstablishedIdleTimeoutSec to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setTcpTimeWaitTimeoutSec(int value)
public RouterNat.Builder setTcpTimeWaitTimeoutSec(int value)
Timeout (in seconds) for TCP connections that are in TIME_WAIT state. Defaults to 120s if not set.
optional int32 tcp_time_wait_timeout_sec = 513596925;
Parameter | |
---|---|
Name | Description |
value | int The tcpTimeWaitTimeoutSec to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setTcpTransitoryIdleTimeoutSec(int value)
public RouterNat.Builder setTcpTransitoryIdleTimeoutSec(int value)
Timeout (in seconds) for TCP transitory connections. Defaults to 30s if not set.
optional int32 tcp_transitory_idle_timeout_sec = 205028774;
Parameter | |
---|---|
Name | Description |
value | int The tcpTransitoryIdleTimeoutSec to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setUdpIdleTimeoutSec(int value)
public RouterNat.Builder setUdpIdleTimeoutSec(int value)
Timeout (in seconds) for UDP connections. Defaults to 30s if not set.
optional int32 udp_idle_timeout_sec = 64919878;
Parameter | |
---|---|
Name | Description |
value | int The udpIdleTimeoutSec to set. |
Returns | |
---|---|
Type | Description |
RouterNat.Builder | This builder for chaining. |
setUnknownFields(UnknownFieldSet unknownFields)
public final RouterNat.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter | |
---|---|
Name | Description |
unknownFields | UnknownFieldSet |
Returns | |
---|---|
Type | Description |
RouterNat.Builder |