Class ClusterSelector.Builder (4.50.0)

public static final class ClusterSelector.Builder extends GeneratedMessageV3.Builder<ClusterSelector.Builder> implements ClusterSelectorOrBuilder

A selector that chooses target cluster for jobs based on metadata.

Protobuf type google.cloud.dataproc.v1.ClusterSelector

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public ClusterSelector.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ClusterSelector.Builder
Overrides

build()

public ClusterSelector build()
Returns
Type Description
ClusterSelector

buildPartial()

public ClusterSelector buildPartial()
Returns
Type Description
ClusterSelector

clear()

public ClusterSelector.Builder clear()
Returns
Type Description
ClusterSelector.Builder
Overrides

clearClusterLabels()

public ClusterSelector.Builder clearClusterLabels()
Returns
Type Description
ClusterSelector.Builder

clearField(Descriptors.FieldDescriptor field)

public ClusterSelector.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
ClusterSelector.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public ClusterSelector.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
ClusterSelector.Builder
Overrides

clearZone()

public ClusterSelector.Builder clearZone()

Optional. The zone where workflow process executes. This parameter does not affect the selection of the cluster.

If unspecified, the zone of the first cluster matching the selector is used.

string zone = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ClusterSelector.Builder

This builder for chaining.

clone()

public ClusterSelector.Builder clone()
Returns
Type Description
ClusterSelector.Builder
Overrides

containsClusterLabels(String key)

public boolean containsClusterLabels(String key)

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
key String
Returns
Type Description
boolean

getClusterLabels() (deprecated)

public Map<String,String> getClusterLabels()
Returns
Type Description
Map<String,String>

getClusterLabelsCount()

public int getClusterLabelsCount()

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
int

getClusterLabelsMap()

public Map<String,String> getClusterLabelsMap()

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Map<String,String>

getClusterLabelsOrDefault(String key, String defaultValue)

public String getClusterLabelsOrDefault(String key, String defaultValue)

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getClusterLabelsOrThrow(String key)

public String getClusterLabelsOrThrow(String key)

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
key String
Returns
Type Description
String

getDefaultInstanceForType()

public ClusterSelector getDefaultInstanceForType()
Returns
Type Description
ClusterSelector

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getMutableClusterLabels() (deprecated)

public Map<String,String> getMutableClusterLabels()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

getZone()

public String getZone()

Optional. The zone where workflow process executes. This parameter does not affect the selection of the cluster.

If unspecified, the zone of the first cluster matching the selector is used.

string zone = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The zone.

getZoneBytes()

public ByteString getZoneBytes()

Optional. The zone where workflow process executes. This parameter does not affect the selection of the cluster.

If unspecified, the zone of the first cluster matching the selector is used.

string zone = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for zone.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ClusterSelector other)

public ClusterSelector.Builder mergeFrom(ClusterSelector other)
Parameter
Name Description
other ClusterSelector
Returns
Type Description
ClusterSelector.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public ClusterSelector.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
ClusterSelector.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public ClusterSelector.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
ClusterSelector.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final ClusterSelector.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ClusterSelector.Builder
Overrides

putAllClusterLabels(Map<String,String> values)

public ClusterSelector.Builder putAllClusterLabels(Map<String,String> values)

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
values Map<String,String>
Returns
Type Description
ClusterSelector.Builder

putClusterLabels(String key, String value)

public ClusterSelector.Builder putClusterLabels(String key, String value)

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Parameters
Name Description
key String
value String
Returns
Type Description
ClusterSelector.Builder

removeClusterLabels(String key)

public ClusterSelector.Builder removeClusterLabels(String key)

Required. The cluster labels. Cluster must have all labels to match.

map<string, string> cluster_labels = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
key String
Returns
Type Description
ClusterSelector.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public ClusterSelector.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ClusterSelector.Builder
Overrides

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

public ClusterSelector.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
ClusterSelector.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final ClusterSelector.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ClusterSelector.Builder
Overrides

setZone(String value)

public ClusterSelector.Builder setZone(String value)

Optional. The zone where workflow process executes. This parameter does not affect the selection of the cluster.

If unspecified, the zone of the first cluster matching the selector is used.

string zone = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The zone to set.

Returns
Type Description
ClusterSelector.Builder

This builder for chaining.

setZoneBytes(ByteString value)

public ClusterSelector.Builder setZoneBytes(ByteString value)

Optional. The zone where workflow process executes. This parameter does not affect the selection of the cluster.

If unspecified, the zone of the first cluster matching the selector is used.

string zone = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for zone to set.

Returns
Type Description
ClusterSelector.Builder

This builder for chaining.