Class OptimizeToursValidationError.FieldReference.Builder (1.53.0)

public static final class OptimizeToursValidationError.FieldReference.Builder extends GeneratedMessageV3.Builder<OptimizeToursValidationError.FieldReference.Builder> implements OptimizeToursValidationError.FieldReferenceOrBuilder

Specifies a context for the validation error. A FieldReference always refers to a given field in this file and follows the same hierarchical structure. For example, we may specify element #2 of start_time_windows of vehicle #5 using: <code><code> name: "vehicles" index: 5 sub_field { name: "end_time_windows" index: 2 } </code></code><code> We however omit top-level entities such as </code>OptimizeToursRequest<code> or </code>ShipmentModel to avoid crowding the message.

Protobuf type google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference

com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public OptimizeToursValidationError.FieldReference.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Overrides

build()

public OptimizeToursValidationError.FieldReference build()

buildPartial()

public OptimizeToursValidationError.FieldReference buildPartial()

clear()

public OptimizeToursValidationError.FieldReference.Builder clear()
Overrides

clearField(Descriptors.FieldDescriptor field)

public OptimizeToursValidationError.FieldReference.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Overrides

clearIndex()

public OptimizeToursValidationError.FieldReference.Builder clearIndex()

Index of the field if repeated.

int32 index = 2;

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

clearIndexOrKey()

public OptimizeToursValidationError.FieldReference.Builder clearIndexOrKey()

clearKey()

public OptimizeToursValidationError.FieldReference.Builder clearKey()

Key if the field is a map.

string key = 4;

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

clearName()

public OptimizeToursValidationError.FieldReference.Builder clearName()

Name of the field, e.g., "vehicles".

string name = 1;

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public OptimizeToursValidationError.FieldReference.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Overrides

clearSubField()

public OptimizeToursValidationError.FieldReference.Builder clearSubField()

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

clone()

public OptimizeToursValidationError.FieldReference.Builder clone()
Overrides

getDefaultInstanceForType()

public OptimizeToursValidationError.FieldReference getDefaultInstanceForType()

getDescriptorForType()

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

getIndex()

public int getIndex()

Index of the field if repeated.

int32 index = 2;

Returns
Type Description
int

The index.

getIndexOrKeyCase()

public OptimizeToursValidationError.FieldReference.IndexOrKeyCase getIndexOrKeyCase()

getKey()

public String getKey()

Key if the field is a map.

string key = 4;

Returns
Type Description
String

The key.

getKeyBytes()

public ByteString getKeyBytes()

Key if the field is a map.

string key = 4;

Returns
Type Description
ByteString

The bytes for key.

getName()

public String getName()

Name of the field, e.g., "vehicles".

string name = 1;

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Name of the field, e.g., "vehicles".

string name = 1;

Returns
Type Description
ByteString

The bytes for name.

getSubField()

public OptimizeToursValidationError.FieldReference getSubField()

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

Returns
Type Description
OptimizeToursValidationError.FieldReference

The subField.

getSubFieldBuilder()

public OptimizeToursValidationError.FieldReference.Builder getSubFieldBuilder()

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

getSubFieldOrBuilder()

public OptimizeToursValidationError.FieldReferenceOrBuilder getSubFieldOrBuilder()

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

hasIndex()

public boolean hasIndex()

Index of the field if repeated.

int32 index = 2;

Returns
Type Description
boolean

Whether the index field is set.

hasKey()

public boolean hasKey()

Key if the field is a map.

string key = 4;

Returns
Type Description
boolean

Whether the key field is set.

hasSubField()

public boolean hasSubField()

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

Returns
Type Description
boolean

Whether the subField field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(OptimizeToursValidationError.FieldReference other)

public OptimizeToursValidationError.FieldReference.Builder mergeFrom(OptimizeToursValidationError.FieldReference other)
Parameter
Name Description
other OptimizeToursValidationError.FieldReference

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

public OptimizeToursValidationError.FieldReference.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Overrides

mergeSubField(OptimizeToursValidationError.FieldReference value)

public OptimizeToursValidationError.FieldReference.Builder mergeSubField(OptimizeToursValidationError.FieldReference value)

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

Parameter
Name Description
value OptimizeToursValidationError.FieldReference

mergeUnknownFields(UnknownFieldSet unknownFields)

public final OptimizeToursValidationError.FieldReference.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public OptimizeToursValidationError.FieldReference.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Overrides

setIndex(int value)

public OptimizeToursValidationError.FieldReference.Builder setIndex(int value)

Index of the field if repeated.

int32 index = 2;

Parameter
Name Description
value int

The index to set.

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

setKey(String value)

public OptimizeToursValidationError.FieldReference.Builder setKey(String value)

Key if the field is a map.

string key = 4;

Parameter
Name Description
value String

The key to set.

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

setKeyBytes(ByteString value)

public OptimizeToursValidationError.FieldReference.Builder setKeyBytes(ByteString value)

Key if the field is a map.

string key = 4;

Parameter
Name Description
value ByteString

The bytes for key to set.

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

setName(String value)

public OptimizeToursValidationError.FieldReference.Builder setName(String value)

Name of the field, e.g., "vehicles".

string name = 1;

Parameter
Name Description
value String

The name to set.

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

setNameBytes(ByteString value)

public OptimizeToursValidationError.FieldReference.Builder setNameBytes(ByteString value)

Name of the field, e.g., "vehicles".

string name = 1;

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
OptimizeToursValidationError.FieldReference.Builder

This builder for chaining.

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

public OptimizeToursValidationError.FieldReference.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Overrides

setSubField(OptimizeToursValidationError.FieldReference value)

public OptimizeToursValidationError.FieldReference.Builder setSubField(OptimizeToursValidationError.FieldReference value)

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

Parameter
Name Description
value OptimizeToursValidationError.FieldReference

setSubField(OptimizeToursValidationError.FieldReference.Builder builderForValue)

public OptimizeToursValidationError.FieldReference.Builder setSubField(OptimizeToursValidationError.FieldReference.Builder builderForValue)

Recursively nested sub-field, if needed.

.google.cloud.optimization.v1.OptimizeToursValidationError.FieldReference sub_field = 3;

Parameter
Name Description
builderForValue OptimizeToursValidationError.FieldReference.Builder

setUnknownFields(UnknownFieldSet unknownFields)

public final OptimizeToursValidationError.FieldReference.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Overrides