Class BoolValue.Builder (0.3.0)

public static final class BoolValue.Builder extends GeneratedMessage.Builder<BoolValue.Builder> implements BoolValueOrBuilder

BoolValue represents a property that has a boolean value type.

Protobuf type google.cloud.apptopology.v1.BoolValue

Implements

BoolValueOrBuilder

Static Methods

getDescriptor()

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

Methods

addAllAllowedValues(Iterable<? extends Boolean> values)

public BoolValue.Builder addAllAllowedValues(Iterable<? extends Boolean> values)

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Parameter
Name Description
values Iterable<? extends java.lang.Boolean>

The allowedValues to add.

Returns
Type Description
BoolValue.Builder

This builder for chaining.

addAllowedValues(boolean value)

public BoolValue.Builder addAllowedValues(boolean value)

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Parameter
Name Description
value boolean

The allowedValues to add.

Returns
Type Description
BoolValue.Builder

This builder for chaining.

build()

public BoolValue build()
Returns
Type Description
BoolValue

buildPartial()

public BoolValue buildPartial()
Returns
Type Description
BoolValue

clear()

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

clearAllowedValues()

public BoolValue.Builder clearAllowedValues()

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Returns
Type Description
BoolValue.Builder

This builder for chaining.

clearRepeated()

public BoolValue.Builder clearRepeated()

OPTIONAL Whether the property is repeated.

bool repeated = 1;

Returns
Type Description
BoolValue.Builder

This builder for chaining.

getAllowedValues(int index)

public boolean getAllowedValues(int index)

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
boolean

The allowedValues at the given index.

getAllowedValuesCount()

public int getAllowedValuesCount()

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Returns
Type Description
int

The count of allowedValues.

getAllowedValuesList()

public List<Boolean> getAllowedValuesList()

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Returns
Type Description
List<Boolean>

A list containing the allowedValues.

getDefaultInstanceForType()

public BoolValue getDefaultInstanceForType()
Returns
Type Description
BoolValue

getDescriptorForType()

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

getRepeated()

public boolean getRepeated()

OPTIONAL Whether the property is repeated.

bool repeated = 1;

Returns
Type Description
boolean

The repeated.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(BoolValue other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setAllowedValues(int index, boolean value)

public BoolValue.Builder setAllowedValues(int index, boolean value)

OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values.

repeated bool allowed_values = 2;

Parameters
Name Description
index int

The index to set the value at.

value boolean

The allowedValues to set.

Returns
Type Description
BoolValue.Builder

This builder for chaining.

setRepeated(boolean value)

public BoolValue.Builder setRepeated(boolean value)

OPTIONAL Whether the property is repeated.

bool repeated = 1;

Parameter
Name Description
value boolean

The repeated to set.

Returns
Type Description
BoolValue.Builder

This builder for chaining.