Class AccessConfig (1.15.0)

public final class AccessConfig extends GeneratedMessageV3 implements AccessConfigOrBuilder

An access configuration attached to an instance's network interface. Only one access config per instance is supported.

Protobuf type google.cloud.compute.v1.AccessConfig

Static Fields

EXTERNAL_IPV6_FIELD_NUMBER

public static final int EXTERNAL_IPV6_FIELD_NUMBER
Field Value
TypeDescription
int

EXTERNAL_IPV6_PREFIX_LENGTH_FIELD_NUMBER

public static final int EXTERNAL_IPV6_PREFIX_LENGTH_FIELD_NUMBER
Field Value
TypeDescription
int

KIND_FIELD_NUMBER

public static final int KIND_FIELD_NUMBER
Field Value
TypeDescription
int

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
TypeDescription
int

NAT_I_P_FIELD_NUMBER

public static final int NAT_I_P_FIELD_NUMBER
Field Value
TypeDescription
int

NETWORK_TIER_FIELD_NUMBER

public static final int NETWORK_TIER_FIELD_NUMBER
Field Value
TypeDescription
int

PUBLIC_PTR_DOMAIN_NAME_FIELD_NUMBER

public static final int PUBLIC_PTR_DOMAIN_NAME_FIELD_NUMBER
Field Value
TypeDescription
int

SET_PUBLIC_PTR_FIELD_NUMBER

public static final int SET_PUBLIC_PTR_FIELD_NUMBER
Field Value
TypeDescription
int

TYPE_FIELD_NUMBER

public static final int TYPE_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static AccessConfig getDefaultInstance()
Returns
TypeDescription
AccessConfig

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static AccessConfig.Builder newBuilder()
Returns
TypeDescription
AccessConfig.Builder

newBuilder(AccessConfig prototype)

public static AccessConfig.Builder newBuilder(AccessConfig prototype)
Parameter
NameDescription
prototypeAccessConfig
Returns
TypeDescription
AccessConfig.Builder

parseDelimitedFrom(InputStream input)

public static AccessConfig parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static AccessConfig parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static AccessConfig parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static AccessConfig parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static AccessConfig parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static AccessConfig parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static AccessConfig parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static AccessConfig parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static AccessConfig parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static AccessConfig parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static AccessConfig parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static AccessConfig parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AccessConfig
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<AccessConfig> parser()
Returns
TypeDescription
Parser<AccessConfig>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public AccessConfig getDefaultInstanceForType()
Returns
TypeDescription
AccessConfig

getExternalIpv6()

public String getExternalIpv6()

The first IPv6 address of the external IPv6 range associated with this instance, prefix length is stored in externalIpv6PrefixLength in ipv6AccessConfig. The field is output only, an IPv6 address from a subnetwork associated with the instance will be allocated dynamically.

optional string external_ipv6 = 532703707;

Returns
TypeDescription
String

The externalIpv6.

getExternalIpv6Bytes()

public ByteString getExternalIpv6Bytes()

The first IPv6 address of the external IPv6 range associated with this instance, prefix length is stored in externalIpv6PrefixLength in ipv6AccessConfig. The field is output only, an IPv6 address from a subnetwork associated with the instance will be allocated dynamically.

optional string external_ipv6 = 532703707;

Returns
TypeDescription
ByteString

The bytes for externalIpv6.

getExternalIpv6PrefixLength()

public int getExternalIpv6PrefixLength()

The prefix length of the external IPv6 range.

optional int32 external_ipv6_prefix_length = 425672143;

Returns
TypeDescription
int

The externalIpv6PrefixLength.

getKind()

public String getKind()

[Output Only] Type of the resource. Always compute#accessConfig for access configs.

optional string kind = 3292052;

Returns
TypeDescription
String

The kind.

getKindBytes()

public ByteString getKindBytes()

[Output Only] Type of the resource. Always compute#accessConfig for access configs.

optional string kind = 3292052;

Returns
TypeDescription
ByteString

The bytes for kind.

getName()

public String getName()

The name of this access configuration. The default and recommended name is External NAT, but you can use any arbitrary string, such as My external IP or Network Access.

optional string name = 3373707;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The name of this access configuration. The default and recommended name is External NAT, but you can use any arbitrary string, such as My external IP or Network Access.

optional string name = 3373707;

Returns
TypeDescription
ByteString

The bytes for name.

getNatIP()

public String getNatIP()

An external IP address associated with this instance. Specify an unused static external IP address available to the project or leave this field undefined to use an IP from a shared ephemeral IP address pool. If you specify a static external IP address, it must live in the same region as the zone of the instance.

optional string nat_i_p = 117634556;

Returns
TypeDescription
String

The natIP.

getNatIPBytes()

public ByteString getNatIPBytes()

An external IP address associated with this instance. Specify an unused static external IP address available to the project or leave this field undefined to use an IP from a shared ephemeral IP address pool. If you specify a static external IP address, it must live in the same region as the zone of the instance.

optional string nat_i_p = 117634556;

Returns
TypeDescription
ByteString

The bytes for natIP.

getNetworkTier()

public String getNetworkTier()

This signifies the networking tier used for configuring this access configuration and can only take the following values: PREMIUM, STANDARD. If an AccessConfig is specified without a valid external IP address, an ephemeral IP will be created with this networkTier. If an AccessConfig with a valid external IP address is specified, it must match that of the networkTier associated with the Address resource owning that IP. Check the NetworkTier enum for the list of possible values.

optional string network_tier = 517397843;

Returns
TypeDescription
String

The networkTier.

getNetworkTierBytes()

public ByteString getNetworkTierBytes()

This signifies the networking tier used for configuring this access configuration and can only take the following values: PREMIUM, STANDARD. If an AccessConfig is specified without a valid external IP address, an ephemeral IP will be created with this networkTier. If an AccessConfig with a valid external IP address is specified, it must match that of the networkTier associated with the Address resource owning that IP. Check the NetworkTier enum for the list of possible values.

optional string network_tier = 517397843;

Returns
TypeDescription
ByteString

The bytes for networkTier.

getParserForType()

public Parser<AccessConfig> getParserForType()
Returns
TypeDescription
Parser<AccessConfig>
Overrides

getPublicPtrDomainName()

public String getPublicPtrDomainName()

The DNS domain name for the public PTR record. You can set this field only if the setPublicPtr field is enabled in accessConfig. If this field is unspecified in ipv6AccessConfig, a default PTR record will be createc for first IP in associated external IPv6 range.

optional string public_ptr_domain_name = 316599167;

Returns
TypeDescription
String

The publicPtrDomainName.

getPublicPtrDomainNameBytes()

public ByteString getPublicPtrDomainNameBytes()

The DNS domain name for the public PTR record. You can set this field only if the setPublicPtr field is enabled in accessConfig. If this field is unspecified in ipv6AccessConfig, a default PTR record will be createc for first IP in associated external IPv6 range.

optional string public_ptr_domain_name = 316599167;

Returns
TypeDescription
ByteString

The bytes for publicPtrDomainName.

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getSetPublicPtr()

public boolean getSetPublicPtr()

Specifies whether a public DNS 'PTR' record should be created to map the external IP address of the instance to a DNS domain name. This field is not used in ipv6AccessConfig. A default PTR record will be created if the VM has external IPv6 range associated.

optional bool set_public_ptr = 523870229;

Returns
TypeDescription
boolean

The setPublicPtr.

getType()

public String getType()

The type of configuration. The default and only option is ONE_TO_ONE_NAT. Check the Type enum for the list of possible values.

optional string type = 3575610;

Returns
TypeDescription
String

The type.

getTypeBytes()

public ByteString getTypeBytes()

The type of configuration. The default and only option is ONE_TO_ONE_NAT. Check the Type enum for the list of possible values.

optional string type = 3575610;

Returns
TypeDescription
ByteString

The bytes for type.

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

hasExternalIpv6()

public boolean hasExternalIpv6()

The first IPv6 address of the external IPv6 range associated with this instance, prefix length is stored in externalIpv6PrefixLength in ipv6AccessConfig. The field is output only, an IPv6 address from a subnetwork associated with the instance will be allocated dynamically.

optional string external_ipv6 = 532703707;

Returns
TypeDescription
boolean

Whether the externalIpv6 field is set.

hasExternalIpv6PrefixLength()

public boolean hasExternalIpv6PrefixLength()

The prefix length of the external IPv6 range.

optional int32 external_ipv6_prefix_length = 425672143;

Returns
TypeDescription
boolean

Whether the externalIpv6PrefixLength field is set.

hasKind()

public boolean hasKind()

[Output Only] Type of the resource. Always compute#accessConfig for access configs.

optional string kind = 3292052;

Returns
TypeDescription
boolean

Whether the kind field is set.

hasName()

public boolean hasName()

The name of this access configuration. The default and recommended name is External NAT, but you can use any arbitrary string, such as My external IP or Network Access.

optional string name = 3373707;

Returns
TypeDescription
boolean

Whether the name field is set.

hasNatIP()

public boolean hasNatIP()

An external IP address associated with this instance. Specify an unused static external IP address available to the project or leave this field undefined to use an IP from a shared ephemeral IP address pool. If you specify a static external IP address, it must live in the same region as the zone of the instance.

optional string nat_i_p = 117634556;

Returns
TypeDescription
boolean

Whether the natIP field is set.

hasNetworkTier()

public boolean hasNetworkTier()

This signifies the networking tier used for configuring this access configuration and can only take the following values: PREMIUM, STANDARD. If an AccessConfig is specified without a valid external IP address, an ephemeral IP will be created with this networkTier. If an AccessConfig with a valid external IP address is specified, it must match that of the networkTier associated with the Address resource owning that IP. Check the NetworkTier enum for the list of possible values.

optional string network_tier = 517397843;

Returns
TypeDescription
boolean

Whether the networkTier field is set.

hasPublicPtrDomainName()

public boolean hasPublicPtrDomainName()

The DNS domain name for the public PTR record. You can set this field only if the setPublicPtr field is enabled in accessConfig. If this field is unspecified in ipv6AccessConfig, a default PTR record will be createc for first IP in associated external IPv6 range.

optional string public_ptr_domain_name = 316599167;

Returns
TypeDescription
boolean

Whether the publicPtrDomainName field is set.

hasSetPublicPtr()

public boolean hasSetPublicPtr()

Specifies whether a public DNS 'PTR' record should be created to map the external IP address of the instance to a DNS domain name. This field is not used in ipv6AccessConfig. A default PTR record will be created if the VM has external IPv6 range associated.

optional bool set_public_ptr = 523870229;

Returns
TypeDescription
boolean

Whether the setPublicPtr field is set.

hasType()

public boolean hasType()

The type of configuration. The default and only option is ONE_TO_ONE_NAT. Check the Type enum for the list of possible values.

optional string type = 3575610;

Returns
TypeDescription
boolean

Whether the type field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public AccessConfig.Builder newBuilderForType()
Returns
TypeDescription
AccessConfig.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected AccessConfig.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
AccessConfig.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public AccessConfig.Builder toBuilder()
Returns
TypeDescription
AccessConfig.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides Exceptions
TypeDescription
IOException