Class EnumTypeOptions.Builder (0.4.0)

public static final class EnumTypeOptions.Builder extends GeneratedMessageV3.Builder<EnumTypeOptions.Builder> implements EnumTypeOptionsOrBuilder

Configurations for an enum/categorical property.

Protobuf type google.cloud.contentwarehouse.v1.EnumTypeOptions

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllPossibleValues(Iterable<String> values)

public EnumTypeOptions.Builder addAllPossibleValues(Iterable<String> values)

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valuesIterable<String>

The possibleValues to add.

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.

addPossibleValues(String value)

public EnumTypeOptions.Builder addPossibleValues(String value)

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The possibleValues to add.

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.

addPossibleValuesBytes(ByteString value)

public EnumTypeOptions.Builder addPossibleValuesBytes(ByteString value)

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes of the possibleValues to add.

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public EnumTypeOptions.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

build()

public EnumTypeOptions build()
Returns
TypeDescription
EnumTypeOptions

buildPartial()

public EnumTypeOptions buildPartial()
Returns
TypeDescription
EnumTypeOptions

clear()

public EnumTypeOptions.Builder clear()
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public EnumTypeOptions.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public EnumTypeOptions.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

clearPossibleValues()

public EnumTypeOptions.Builder clearPossibleValues()

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.

clearValidationCheckDisabled()

public EnumTypeOptions.Builder clearValidationCheckDisabled()

Make sure the Enum property value provided in the document is in the possile value list during document creation. The validation check runs by default.

bool validation_check_disabled = 2;

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.

clone()

public EnumTypeOptions.Builder clone()
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

getDefaultInstanceForType()

public EnumTypeOptions getDefaultInstanceForType()
Returns
TypeDescription
EnumTypeOptions

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getPossibleValues(int index)

public String getPossibleValues(int index)

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The possibleValues at the given index.

getPossibleValuesBytes(int index)

public ByteString getPossibleValuesBytes(int index)

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the possibleValues at the given index.

getPossibleValuesCount()

public int getPossibleValuesCount()

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
int

The count of possibleValues.

getPossibleValuesList()

public ProtocolStringList getPossibleValuesList()

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ProtocolStringList

A list containing the possibleValues.

getValidationCheckDisabled()

public boolean getValidationCheckDisabled()

Make sure the Enum property value provided in the document is in the possile value list during document creation. The validation check runs by default.

bool validation_check_disabled = 2;

Returns
TypeDescription
boolean

The validationCheckDisabled.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(EnumTypeOptions other)

public EnumTypeOptions.Builder mergeFrom(EnumTypeOptions other)
Parameter
NameDescription
otherEnumTypeOptions
Returns
TypeDescription
EnumTypeOptions.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public EnumTypeOptions.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public EnumTypeOptions.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final EnumTypeOptions.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public EnumTypeOptions.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

setPossibleValues(int index, String value)

public EnumTypeOptions.Builder setPossibleValues(int index, String value)

Required. List of possible enum values.

repeated string possible_values = 1 [(.google.api.field_behavior) = REQUIRED];

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The possibleValues to set.

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.

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

public EnumTypeOptions.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final EnumTypeOptions.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
EnumTypeOptions.Builder
Overrides

setValidationCheckDisabled(boolean value)

public EnumTypeOptions.Builder setValidationCheckDisabled(boolean value)

Make sure the Enum property value provided in the document is in the possile value list during document creation. The validation check runs by default.

bool validation_check_disabled = 2;

Parameter
NameDescription
valueboolean

The validationCheckDisabled to set.

Returns
TypeDescription
EnumTypeOptions.Builder

This builder for chaining.