Class Label.Builder (2.55.0)

public static final class Label.Builder extends GeneratedMessageV3.Builder<Label.Builder> implements LabelOrBuilder

Represents a generic name-value label. A label has separate name and value fields to support filtering with the contains() function. For more information, see Filtering on array-type fields.

Protobuf type google.cloud.securitycenter.v1.Label

Implements

LabelOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Label build()
Returns
Type Description
Label

buildPartial()

public Label buildPartial()
Returns
Type Description
Label

clear()

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

clearField(Descriptors.FieldDescriptor field)

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

clearName()

public Label.Builder clearName()

Name of the label.

string name = 1;

Returns
Type Description
Label.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearValue()

public Label.Builder clearValue()

Value that corresponds to the label's name.

string value = 2;

Returns
Type Description
Label.Builder

This builder for chaining.

clone()

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

getDefaultInstanceForType()

public Label getDefaultInstanceForType()
Returns
Type Description
Label

getDescriptorForType()

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

getName()

public String getName()

Name of the label.

string name = 1;

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Name of the label.

string name = 1;

Returns
Type Description
ByteString

The bytes for name.

getValue()

public String getValue()

Value that corresponds to the label's name.

string value = 2;

Returns
Type Description
String

The value.

getValueBytes()

public ByteString getValueBytes()

Value that corresponds to the label's name.

string value = 2;

Returns
Type Description
ByteString

The bytes for value.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(Label other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setField(Descriptors.FieldDescriptor field, Object value)

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

setName(String value)

public Label.Builder setName(String value)

Name of the label.

string name = 1;

Parameter
Name Description
value String

The name to set.

Returns
Type Description
Label.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Label.Builder setNameBytes(ByteString value)

Name of the label.

string name = 1;

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
Label.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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

setValue(String value)

public Label.Builder setValue(String value)

Value that corresponds to the label's name.

string value = 2;

Parameter
Name Description
value String

The value to set.

Returns
Type Description
Label.Builder

This builder for chaining.

setValueBytes(ByteString value)

public Label.Builder setValueBytes(ByteString value)

Value that corresponds to the label's name.

string value = 2;

Parameter
Name Description
value ByteString

The bytes for value to set.

Returns
Type Description
Label.Builder

This builder for chaining.