Class Volume.Builder (0.39.0)

public static final class Volume.Builder extends GeneratedMessageV3.Builder<Volume.Builder> implements VolumeOrBuilder

Volume represents a named volume in a container.

Protobuf type google.cloud.run.v2.Volume

Implements

VolumeOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Volume.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Volume.Builder
Overrides

build()

public Volume build()
Returns
TypeDescription
Volume

buildPartial()

public Volume buildPartial()
Returns
TypeDescription
Volume

clear()

public Volume.Builder clear()
Returns
TypeDescription
Volume.Builder
Overrides

clearCloudSqlInstance()

public Volume.Builder clearCloudSqlInstance()

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Returns
TypeDescription
Volume.Builder

clearEmptyDir()

public Volume.Builder clearEmptyDir()

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Returns
TypeDescription
Volume.Builder

clearField(Descriptors.FieldDescriptor field)

public Volume.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Volume.Builder
Overrides

clearGcs()

public Volume.Builder clearGcs()

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Returns
TypeDescription
Volume.Builder

clearName()

public Volume.Builder clearName()

Required. Volume's name.

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Volume.Builder

This builder for chaining.

clearNfs()

public Volume.Builder clearNfs()

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Returns
TypeDescription
Volume.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public Volume.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Volume.Builder
Overrides

clearSecret()

public Volume.Builder clearSecret()

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Returns
TypeDescription
Volume.Builder

clearVolumeType()

public Volume.Builder clearVolumeType()
Returns
TypeDescription
Volume.Builder

clone()

public Volume.Builder clone()
Returns
TypeDescription
Volume.Builder
Overrides

getCloudSqlInstance()

public CloudSqlInstance getCloudSqlInstance()

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Returns
TypeDescription
CloudSqlInstance

The cloudSqlInstance.

getCloudSqlInstanceBuilder()

public CloudSqlInstance.Builder getCloudSqlInstanceBuilder()

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Returns
TypeDescription
CloudSqlInstance.Builder

getCloudSqlInstanceOrBuilder()

public CloudSqlInstanceOrBuilder getCloudSqlInstanceOrBuilder()

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Returns
TypeDescription
CloudSqlInstanceOrBuilder

getDefaultInstanceForType()

public Volume getDefaultInstanceForType()
Returns
TypeDescription
Volume

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEmptyDir()

public EmptyDirVolumeSource getEmptyDir()

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Returns
TypeDescription
EmptyDirVolumeSource

The emptyDir.

getEmptyDirBuilder()

public EmptyDirVolumeSource.Builder getEmptyDirBuilder()

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Returns
TypeDescription
EmptyDirVolumeSource.Builder

getEmptyDirOrBuilder()

public EmptyDirVolumeSourceOrBuilder getEmptyDirOrBuilder()

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Returns
TypeDescription
EmptyDirVolumeSourceOrBuilder

getGcs()

public GCSVolumeSource getGcs()

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Returns
TypeDescription
GCSVolumeSource

The gcs.

getGcsBuilder()

public GCSVolumeSource.Builder getGcsBuilder()

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Returns
TypeDescription
GCSVolumeSource.Builder

getGcsOrBuilder()

public GCSVolumeSourceOrBuilder getGcsOrBuilder()

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Returns
TypeDescription
GCSVolumeSourceOrBuilder

getName()

public String getName()

Required. Volume's name.

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Required. Volume's name.

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for name.

getNfs()

public NFSVolumeSource getNfs()

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Returns
TypeDescription
NFSVolumeSource

The nfs.

getNfsBuilder()

public NFSVolumeSource.Builder getNfsBuilder()

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Returns
TypeDescription
NFSVolumeSource.Builder

getNfsOrBuilder()

public NFSVolumeSourceOrBuilder getNfsOrBuilder()

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Returns
TypeDescription
NFSVolumeSourceOrBuilder

getSecret()

public SecretVolumeSource getSecret()

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Returns
TypeDescription
SecretVolumeSource

The secret.

getSecretBuilder()

public SecretVolumeSource.Builder getSecretBuilder()

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Returns
TypeDescription
SecretVolumeSource.Builder

getSecretOrBuilder()

public SecretVolumeSourceOrBuilder getSecretOrBuilder()

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Returns
TypeDescription
SecretVolumeSourceOrBuilder

getVolumeTypeCase()

public Volume.VolumeTypeCase getVolumeTypeCase()
Returns
TypeDescription
Volume.VolumeTypeCase

hasCloudSqlInstance()

public boolean hasCloudSqlInstance()

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Returns
TypeDescription
boolean

Whether the cloudSqlInstance field is set.

hasEmptyDir()

public boolean hasEmptyDir()

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Returns
TypeDescription
boolean

Whether the emptyDir field is set.

hasGcs()

public boolean hasGcs()

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Returns
TypeDescription
boolean

Whether the gcs field is set.

hasNfs()

public boolean hasNfs()

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Returns
TypeDescription
boolean

Whether the nfs field is set.

hasSecret()

public boolean hasSecret()

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Returns
TypeDescription
boolean

Whether the secret field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeCloudSqlInstance(CloudSqlInstance value)

public Volume.Builder mergeCloudSqlInstance(CloudSqlInstance value)

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Parameter
NameDescription
valueCloudSqlInstance
Returns
TypeDescription
Volume.Builder

mergeEmptyDir(EmptyDirVolumeSource value)

public Volume.Builder mergeEmptyDir(EmptyDirVolumeSource value)

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Parameter
NameDescription
valueEmptyDirVolumeSource
Returns
TypeDescription
Volume.Builder

mergeFrom(Volume other)

public Volume.Builder mergeFrom(Volume other)
Parameter
NameDescription
otherVolume
Returns
TypeDescription
Volume.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Volume.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Volume.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Volume.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Volume.Builder
Overrides

mergeGcs(GCSVolumeSource value)

public Volume.Builder mergeGcs(GCSVolumeSource value)

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Parameter
NameDescription
valueGCSVolumeSource
Returns
TypeDescription
Volume.Builder

mergeNfs(NFSVolumeSource value)

public Volume.Builder mergeNfs(NFSVolumeSource value)

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Parameter
NameDescription
valueNFSVolumeSource
Returns
TypeDescription
Volume.Builder

mergeSecret(SecretVolumeSource value)

public Volume.Builder mergeSecret(SecretVolumeSource value)

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Parameter
NameDescription
valueSecretVolumeSource
Returns
TypeDescription
Volume.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Volume.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Volume.Builder
Overrides

setCloudSqlInstance(CloudSqlInstance value)

public Volume.Builder setCloudSqlInstance(CloudSqlInstance value)

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Parameter
NameDescription
valueCloudSqlInstance
Returns
TypeDescription
Volume.Builder

setCloudSqlInstance(CloudSqlInstance.Builder builderForValue)

public Volume.Builder setCloudSqlInstance(CloudSqlInstance.Builder builderForValue)

For Cloud SQL volumes, contains the specific instances that should be mounted. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run.

.google.cloud.run.v2.CloudSqlInstance cloud_sql_instance = 3;

Parameter
NameDescription
builderForValueCloudSqlInstance.Builder
Returns
TypeDescription
Volume.Builder

setEmptyDir(EmptyDirVolumeSource value)

public Volume.Builder setEmptyDir(EmptyDirVolumeSource value)

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Parameter
NameDescription
valueEmptyDirVolumeSource
Returns
TypeDescription
Volume.Builder

setEmptyDir(EmptyDirVolumeSource.Builder builderForValue)

public Volume.Builder setEmptyDir(EmptyDirVolumeSource.Builder builderForValue)

Ephemeral storage used as a shared volume.

.google.cloud.run.v2.EmptyDirVolumeSource empty_dir = 4;

Parameter
NameDescription
builderForValueEmptyDirVolumeSource.Builder
Returns
TypeDescription
Volume.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public Volume.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Volume.Builder
Overrides

setGcs(GCSVolumeSource value)

public Volume.Builder setGcs(GCSVolumeSource value)

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Parameter
NameDescription
valueGCSVolumeSource
Returns
TypeDescription
Volume.Builder

setGcs(GCSVolumeSource.Builder builderForValue)

public Volume.Builder setGcs(GCSVolumeSource.Builder builderForValue)

Persistent storage backed by a Google Cloud Storage bucket.

.google.cloud.run.v2.GCSVolumeSource gcs = 6;

Parameter
NameDescription
builderForValueGCSVolumeSource.Builder
Returns
TypeDescription
Volume.Builder

setName(String value)

public Volume.Builder setName(String value)

Required. Volume's name.

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
Volume.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Volume.Builder setNameBytes(ByteString value)

Required. Volume's name.

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
Volume.Builder

This builder for chaining.

setNfs(NFSVolumeSource value)

public Volume.Builder setNfs(NFSVolumeSource value)

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Parameter
NameDescription
valueNFSVolumeSource
Returns
TypeDescription
Volume.Builder

setNfs(NFSVolumeSource.Builder builderForValue)

public Volume.Builder setNfs(NFSVolumeSource.Builder builderForValue)

For NFS Voumes, contains the path to the nfs Volume

.google.cloud.run.v2.NFSVolumeSource nfs = 5;

Parameter
NameDescription
builderForValueNFSVolumeSource.Builder
Returns
TypeDescription
Volume.Builder

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public Volume.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Volume.Builder
Overrides

setSecret(SecretVolumeSource value)

public Volume.Builder setSecret(SecretVolumeSource value)

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Parameter
NameDescription
valueSecretVolumeSource
Returns
TypeDescription
Volume.Builder

setSecret(SecretVolumeSource.Builder builderForValue)

public Volume.Builder setSecret(SecretVolumeSource.Builder builderForValue)

Secret represents a secret that should populate this volume.

.google.cloud.run.v2.SecretVolumeSource secret = 2;

Parameter
NameDescription
builderForValueSecretVolumeSource.Builder
Returns
TypeDescription
Volume.Builder

setUnknownFields(UnknownFieldSet unknownFields)

public final Volume.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Volume.Builder
Overrides