Class AllocationAffinity.Builder (0.10.0)
Stay organized with collections
Save and categorize content based on your preferences.
publicstaticfinalclass AllocationAffinity.BuilderextendsGeneratedMessageV3.Builder<AllocationAffinity.Builder>implementsAllocationAffinityOrBuilderSpecifies the reservations that this instance can consume from.
Protobuf type google.cloud.backupdr.v1.AllocationAffinity
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > AllocationAffinity.BuilderImplements
AllocationAffinityOrBuilderInherited Members
Static Methods
getDescriptor()
publicstaticfinalDescriptors.DescriptorgetDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
addAllValues(Iterable<String> values)
publicAllocationAffinity.BuilderaddAllValues(Iterable<String>values)Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
values |
Iterable<String>The values to add. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
publicAllocationAffinity.BuilderaddRepeatedField(Descriptors.FieldDescriptorfield,Objectvalue)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
addValues(String value)
publicAllocationAffinity.BuilderaddValues(Stringvalue)Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
String The values to add. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
addValuesBytes(ByteString value)
publicAllocationAffinity.BuilderaddValuesBytes(ByteStringvalue)Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteString The bytes of the values to add. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
build()
publicAllocationAffinitybuild()| Returns | |
|---|---|
| Type | Description |
AllocationAffinity |
|
buildPartial()
publicAllocationAffinitybuildPartial()| Returns | |
|---|---|
| Type | Description |
AllocationAffinity |
|
clear()
publicAllocationAffinity.Builderclear()| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
clearConsumeAllocationType()
publicAllocationAffinity.BuilderclearConsumeAllocationType()Optional. Specifies the type of reservation from which this instance can consume
optional .google.cloud.backupdr.v1.AllocationAffinity.Type consume_allocation_type = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
clearField(Descriptors.FieldDescriptor field)
publicAllocationAffinity.BuilderclearField(Descriptors.FieldDescriptorfield)| Parameter | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
clearKey()
publicAllocationAffinity.BuilderclearKey()Optional. Corresponds to the label key of a reservation resource.
optional string key = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
publicAllocationAffinity.BuilderclearOneof(Descriptors.OneofDescriptoroneof)| Parameter | |
|---|---|
| Name | Description |
oneof |
OneofDescriptor |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
clearValues()
publicAllocationAffinity.BuilderclearValues()Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
clone()
publicAllocationAffinity.Builderclone()| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
getConsumeAllocationType()
publicAllocationAffinity.TypegetConsumeAllocationType()Optional. Specifies the type of reservation from which this instance can consume
optional .google.cloud.backupdr.v1.AllocationAffinity.Type consume_allocation_type = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Type |
The consumeAllocationType. |
getConsumeAllocationTypeValue()
publicintgetConsumeAllocationTypeValue()Optional. Specifies the type of reservation from which this instance can consume
optional .google.cloud.backupdr.v1.AllocationAffinity.Type consume_allocation_type = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
int |
The enum numeric value on the wire for consumeAllocationType. |
getDefaultInstanceForType()
publicAllocationAffinitygetDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
AllocationAffinity |
|
getDescriptorForType()
publicDescriptors.DescriptorgetDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getKey()
publicStringgetKey()Optional. Corresponds to the label key of a reservation resource.
optional string key = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
String |
The key. |
getKeyBytes()
publicByteStringgetKeyBytes()Optional. Corresponds to the label key of a reservation resource.
optional string key = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for key. |
getValues(int index)
publicStringgetValues(intindex)Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
index |
int The index of the element to return. |
| Returns | |
|---|---|
| Type | Description |
String |
The values at the given index. |
getValuesBytes(int index)
publicByteStringgetValuesBytes(intindex)Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
index |
int The index of the value to return. |
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes of the values at the given index. |
getValuesCount()
publicintgetValuesCount()Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
int |
The count of values. |
getValuesList()
publicProtocolStringListgetValuesList()Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ProtocolStringList |
A list containing the values. |
hasConsumeAllocationType()
publicbooleanhasConsumeAllocationType()Optional. Specifies the type of reservation from which this instance can consume
optional .google.cloud.backupdr.v1.AllocationAffinity.Type consume_allocation_type = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the consumeAllocationType field is set. |
hasKey()
publicbooleanhasKey()Optional. Corresponds to the label key of a reservation resource.
optional string key = 2 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the key field is set. |
internalGetFieldAccessorTable()
protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
publicfinalbooleanisInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(AllocationAffinity other)
publicAllocationAffinity.BuildermergeFrom(AllocationAffinityother)| Parameter | |
|---|---|
| Name | Description |
other |
AllocationAffinity |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
publicAllocationAffinity.BuildermergeFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
publicAllocationAffinity.BuildermergeFrom(Messageother)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
mergeUnknownFields(UnknownFieldSet unknownFields)
publicfinalAllocationAffinity.BuildermergeUnknownFields(UnknownFieldSetunknownFields)| Parameter | |
|---|---|
| Name | Description |
unknownFields |
UnknownFieldSet |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
setConsumeAllocationType(AllocationAffinity.Type value)
publicAllocationAffinity.BuildersetConsumeAllocationType(AllocationAffinity.Typevalue)Optional. Specifies the type of reservation from which this instance can consume
optional .google.cloud.backupdr.v1.AllocationAffinity.Type consume_allocation_type = 1 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
AllocationAffinity.Type The consumeAllocationType to set. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
setConsumeAllocationTypeValue(int value)
publicAllocationAffinity.BuildersetConsumeAllocationTypeValue(intvalue)Optional. Specifies the type of reservation from which this instance can consume
optional .google.cloud.backupdr.v1.AllocationAffinity.Type consume_allocation_type = 1 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
int The enum numeric value on the wire for consumeAllocationType to set. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
setField(Descriptors.FieldDescriptor field, Object value)
publicAllocationAffinity.BuildersetField(Descriptors.FieldDescriptorfield,Objectvalue)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
setKey(String value)
publicAllocationAffinity.BuildersetKey(Stringvalue)Optional. Corresponds to the label key of a reservation resource.
optional string key = 2 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
String The key to set. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
setKeyBytes(ByteString value)
publicAllocationAffinity.BuildersetKeyBytes(ByteStringvalue)Optional. Corresponds to the label key of a reservation resource.
optional string key = 2 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteString The bytes for key to set. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
publicAllocationAffinity.BuildersetRepeatedField(Descriptors.FieldDescriptorfield,intindex,Objectvalue)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
index |
int |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
setUnknownFields(UnknownFieldSet unknownFields)
publicfinalAllocationAffinity.BuildersetUnknownFields(UnknownFieldSetunknownFields)| Parameter | |
|---|---|
| Name | Description |
unknownFields |
UnknownFieldSet |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
|
setValues(int index, String value)
publicAllocationAffinity.BuildersetValues(intindex,Stringvalue)Optional. Corresponds to the label values of a reservation resource.
repeated string values = 3 [(.google.api.field_behavior) = OPTIONAL];
| Parameters | |
|---|---|
| Name | Description |
index |
int The index to set the value at. |
value |
String The values to set. |
| Returns | |
|---|---|
| Type | Description |
AllocationAffinity.Builder |
This builder for chaining. |