Class Partition.Builder (1.25.0)

public static final class Partition.Builder extends GeneratedMessageV3.Builder<Partition.Builder> implements PartitionOrBuilder

Represents partition metadata contained within entity instances.

Protobuf type google.cloud.dataplex.v1.Partition

Implements

PartitionOrBuilder

Static Methods

getDescriptor()

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

Methods

addAllValues(Iterable<String> values)

public Partition.Builder addAllValues(Iterable<String> values)

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valuesIterable<String>

The values to add.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

addValues(String value)

public Partition.Builder addValues(String value)

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueString

The values to add.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

addValuesBytes(ByteString value)

public Partition.Builder addValuesBytes(ByteString value)

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueByteString

The bytes of the values to add.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

build()

public Partition build()
Returns
TypeDescription
Partition

buildPartial()

public Partition buildPartial()
Returns
TypeDescription
Partition

clear()

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

clearEtag() (deprecated)

public Partition.Builder clearEtag()

Deprecated. google.cloud.dataplex.v1.Partition.etag is deprecated. See google/cloud/dataplex/v1/metadata.proto;l=513

Optional. The etag for this partition.

string etag = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Partition.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearLocation()

public Partition.Builder clearLocation()

Required. Immutable. The location of the entity data within the partition, for example, gs://bucket/path/to/entity/key1=value1/key2=value2. Or projects/<project_id>/datasets/<dataset_id>/tables/<table_id>

string location = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
Partition.Builder

This builder for chaining.

clearName()

public Partition.Builder clearName()

Output only. Partition values used in the HTTP URL must be double encoded. For example, url_encode(url_encode(value)) can be used to encode "US:CA/CA#Sunnyvale so that the request URL ends with "/partitions/US%253ACA/CA%2523Sunnyvale". The name field in the response retains the encoded format.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Returns
TypeDescription
Partition.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearValues()

public Partition.Builder clearValues()

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
Partition.Builder

This builder for chaining.

clone()

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

getDefaultInstanceForType()

public Partition getDefaultInstanceForType()
Returns
TypeDescription
Partition

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEtag() (deprecated)

public String getEtag()

Deprecated. google.cloud.dataplex.v1.Partition.etag is deprecated. See google/cloud/dataplex/v1/metadata.proto;l=513

Optional. The etag for this partition.

string etag = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The etag.

getEtagBytes() (deprecated)

public ByteString getEtagBytes()

Deprecated. google.cloud.dataplex.v1.Partition.etag is deprecated. See google/cloud/dataplex/v1/metadata.proto;l=513

Optional. The etag for this partition.

string etag = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for etag.

getLocation()

public String getLocation()

Required. Immutable. The location of the entity data within the partition, for example, gs://bucket/path/to/entity/key1=value1/key2=value2. Or projects/<project_id>/datasets/<dataset_id>/tables/<table_id>

string location = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
String

The location.

getLocationBytes()

public ByteString getLocationBytes()

Required. Immutable. The location of the entity data within the partition, for example, gs://bucket/path/to/entity/key1=value1/key2=value2. Or projects/<project_id>/datasets/<dataset_id>/tables/<table_id>

string location = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
ByteString

The bytes for location.

getName()

public String getName()

Output only. Partition values used in the HTTP URL must be double encoded. For example, url_encode(url_encode(value)) can be used to encode "US:CA/CA#Sunnyvale so that the request URL ends with "/partitions/US%253ACA/CA%2523Sunnyvale". The name field in the response retains the encoded format.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Output only. Partition values used in the HTTP URL must be double encoded. For example, url_encode(url_encode(value)) can be used to encode "US:CA/CA#Sunnyvale so that the request URL ends with "/partitions/US%253ACA/CA%2523Sunnyvale". The name field in the response retains the encoded format.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Returns
TypeDescription
ByteString

The bytes for name.

getValues(int index)

public String getValues(int index)

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The values at the given index.

getValuesBytes(int index)

public ByteString getValuesBytes(int index)

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the values at the given index.

getValuesCount()

public int getValuesCount()

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
int

The count of values.

getValuesList()

public ProtocolStringList getValuesList()

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
ProtocolStringList

A list containing the values.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(Partition other)

public Partition.Builder mergeFrom(Partition other)
Parameter
NameDescription
otherPartition
Returns
TypeDescription
Partition.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setEtag(String value) (deprecated)

public Partition.Builder setEtag(String value)

Deprecated. google.cloud.dataplex.v1.Partition.etag is deprecated. See google/cloud/dataplex/v1/metadata.proto;l=513

Optional. The etag for this partition.

string etag = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The etag to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

setEtagBytes(ByteString value) (deprecated)

public Partition.Builder setEtagBytes(ByteString value)

Deprecated. google.cloud.dataplex.v1.Partition.etag is deprecated. See google/cloud/dataplex/v1/metadata.proto;l=513

Optional. The etag for this partition.

string etag = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes for etag to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setLocation(String value)

public Partition.Builder setLocation(String value)

Required. Immutable. The location of the entity data within the partition, for example, gs://bucket/path/to/entity/key1=value1/key2=value2. Or projects/<project_id>/datasets/<dataset_id>/tables/<table_id>

string location = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueString

The location to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

setLocationBytes(ByteString value)

public Partition.Builder setLocationBytes(ByteString value)

Required. Immutable. The location of the entity data within the partition, for example, gs://bucket/path/to/entity/key1=value1/key2=value2. Or projects/<project_id>/datasets/<dataset_id>/tables/<table_id>

string location = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueByteString

The bytes for location to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

setName(String value)

public Partition.Builder setName(String value)

Output only. Partition values used in the HTTP URL must be double encoded. For example, url_encode(url_encode(value)) can be used to encode "US:CA/CA#Sunnyvale so that the request URL ends with "/partitions/US%253ACA/CA%2523Sunnyvale". The name field in the response retains the encoded format.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Partition.Builder setNameBytes(ByteString value)

Output only. Partition values used in the HTTP URL must be double encoded. For example, url_encode(url_encode(value)) can be used to encode "US:CA/CA#Sunnyvale so that the request URL ends with "/partitions/US%253ACA/CA%2523Sunnyvale". The name field in the response retains the encoded format.

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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

setValues(int index, String value)

public Partition.Builder setValues(int index, String value)

Required. Immutable. The set of values representing the partition, which correspond to the partition schema defined in the parent entity.

repeated string values = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The values to set.

Returns
TypeDescription
Partition.Builder

This builder for chaining.