public static final class KeyValuePair.Builder extends GeneratedMessage.Builder<KeyValuePair.Builder> implements KeyValuePairOrBuilderKeyValuePair defines a key-value pair for matching resource labels.
Protobuf type google.cloud.backupdr.v1beta.KeyValuePair
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > KeyValuePair.BuilderImplements
KeyValuePairOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
addAllValues(Iterable<String> values)
public KeyValuePair.Builder addAllValues(Iterable<String> values) Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
values |
Iterable<String>The values to add. |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
addValues(String value)
public KeyValuePair.Builder addValues(String value) Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe values to add. |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
addValuesBytes(ByteString value)
public KeyValuePair.Builder addValuesBytes(ByteString value) Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes of the values to add. |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
build()
public KeyValuePair build()| Returns | |
|---|---|
| Type | Description |
KeyValuePair |
|
buildPartial()
public KeyValuePair buildPartial()| Returns | |
|---|---|
| Type | Description |
KeyValuePair |
|
clear()
public KeyValuePair.Builder clear()| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
|
clearKey()
public KeyValuePair.Builder clearKey() Required. The key of the label to match.
This must be in the format {label_key}.
The key must match the regex
Format:\p{Ll}\p{Lo}{0,62}.
string key = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
clearValues()
public KeyValuePair.Builder clearValues() Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
getDefaultInstanceForType()
public KeyValuePair getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
KeyValuePair |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getKey()
public String getKey() Required. The key of the label to match.
This must be in the format {label_key}.
The key must match the regex
Format:\p{Ll}\p{Lo}{0,62}.
string key = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
String |
The key. |
getKeyBytes()
public ByteString getKeyBytes() Required. The key of the label to match.
This must be in the format {label_key}.
The key must match the regex
Format:\p{Ll}\p{Lo}{0,62}.
string key = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for key. |
getValues(int index)
public String getValues(int index) Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
index |
intThe index of the element to return. |
| Returns | |
|---|---|
| Type | Description |
String |
The values at the given index. |
getValuesBytes(int index)
public ByteString getValuesBytes(int index) Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
index |
intThe index of the value to return. |
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes of the values at the given index. |
getValuesCount()
public int getValuesCount() Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
int |
The count of values. |
getValuesList()
public ProtocolStringList getValuesList() Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
ProtocolStringList |
A list containing the values. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(KeyValuePair other)
public KeyValuePair.Builder mergeFrom(KeyValuePair other)| Parameter | |
|---|---|
| Name | Description |
other |
KeyValuePair |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public KeyValuePair.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public KeyValuePair.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
|
setKey(String value)
public KeyValuePair.Builder setKey(String value) Required. The key of the label to match.
This must be in the format {label_key}.
The key must match the regex
Format:\p{Ll}\p{Lo}{0,62}.
string key = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe key to set. |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
setKeyBytes(ByteString value)
public KeyValuePair.Builder setKeyBytes(ByteString value) Required. The key of the label to match.
This must be in the format {label_key}.
The key must match the regex
Format:\p{Ll}\p{Lo}{0,62}.
string key = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for key to set. |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |
setValues(int index, String value)
public KeyValuePair.Builder setValues(int index, String value) Required. The values of the label to match.
There will be explicit “OR” between values of array.
Each value must be in the format {label_value}.
The value must match the regex
Format: [\\p{Ll}\\p{Lo}\\p{N}_-]{1,63}.
repeated string values = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameters | |
|---|---|
| Name | Description |
index |
intThe index to set the value at. |
value |
StringThe values to set. |
| Returns | |
|---|---|
| Type | Description |
KeyValuePair.Builder |
This builder for chaining. |