public static final class ShipmentModel.DurationDistanceMatrix.Builder extends GeneratedMessageV3.Builder<ShipmentModel.DurationDistanceMatrix.Builder> implements ShipmentModel.DurationDistanceMatrixOrBuilder
Specifies a duration and distance matrix from visit and vehicle start
locations to visit and vehicle end locations.
Protobuf type google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
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
Methods
addAllRows(Iterable<? extends ShipmentModel.DurationDistanceMatrix.Row> values)
public ShipmentModel.DurationDistanceMatrix.Builder addAllRows(Iterable<? extends ShipmentModel.DurationDistanceMatrix.Row> values)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Name | Description |
values | Iterable<? extends com.google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row>
|
Returns
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public ShipmentModel.DurationDistanceMatrix.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
addRows(ShipmentModel.DurationDistanceMatrix.Row value)
public ShipmentModel.DurationDistanceMatrix.Builder addRows(ShipmentModel.DurationDistanceMatrix.Row value)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
addRows(ShipmentModel.DurationDistanceMatrix.Row.Builder builderForValue)
public ShipmentModel.DurationDistanceMatrix.Builder addRows(ShipmentModel.DurationDistanceMatrix.Row.Builder builderForValue)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
addRows(int index, ShipmentModel.DurationDistanceMatrix.Row value)
public ShipmentModel.DurationDistanceMatrix.Builder addRows(int index, ShipmentModel.DurationDistanceMatrix.Row value)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameters
Returns
addRows(int index, ShipmentModel.DurationDistanceMatrix.Row.Builder builderForValue)
public ShipmentModel.DurationDistanceMatrix.Builder addRows(int index, ShipmentModel.DurationDistanceMatrix.Row.Builder builderForValue)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameters
Returns
addRowsBuilder()
public ShipmentModel.DurationDistanceMatrix.Row.Builder addRowsBuilder()
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Returns
addRowsBuilder(int index)
public ShipmentModel.DurationDistanceMatrix.Row.Builder addRowsBuilder(int index)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
build()
public ShipmentModel.DurationDistanceMatrix build()
Returns
buildPartial()
public ShipmentModel.DurationDistanceMatrix buildPartial()
Returns
clear()
public ShipmentModel.DurationDistanceMatrix.Builder clear()
Returns
Overrides
clearField(Descriptors.FieldDescriptor field)
public ShipmentModel.DurationDistanceMatrix.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearOneof(Descriptors.OneofDescriptor oneof)
public ShipmentModel.DurationDistanceMatrix.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearRows()
public ShipmentModel.DurationDistanceMatrix.Builder clearRows()
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Returns
clearVehicleStartTag()
public ShipmentModel.DurationDistanceMatrix.Builder clearVehicleStartTag()
Tag defining to which vehicles this duration and distance matrix applies.
If empty, this applies to all vehicles, and there can only be a single
matrix.
Each vehicle start must match exactly one matrix, i.e. exactly one of
their start_tags
field must match the vehicle_start_tag
of a matrix
(and of that matrix only).
All matrices must have a different vehicle_start_tag
.
string vehicle_start_tag = 2;
Returns
clone()
public ShipmentModel.DurationDistanceMatrix.Builder clone()
Returns
Overrides
getDefaultInstanceForType()
public ShipmentModel.DurationDistanceMatrix getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getRows(int index)
public ShipmentModel.DurationDistanceMatrix.Row getRows(int index)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
getRowsBuilder(int index)
public ShipmentModel.DurationDistanceMatrix.Row.Builder getRowsBuilder(int index)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
getRowsBuilderList()
public List<ShipmentModel.DurationDistanceMatrix.Row.Builder> getRowsBuilderList()
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Returns
getRowsCount()
public int getRowsCount()
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Returns
getRowsList()
public List<ShipmentModel.DurationDistanceMatrix.Row> getRowsList()
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Returns
getRowsOrBuilder(int index)
public ShipmentModel.DurationDistanceMatrix.RowOrBuilder getRowsOrBuilder(int index)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
getRowsOrBuilderList()
public List<? extends ShipmentModel.DurationDistanceMatrix.RowOrBuilder> getRowsOrBuilderList()
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Returns
Type | Description |
List<? extends com.google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.RowOrBuilder> | |
getVehicleStartTag()
public String getVehicleStartTag()
Tag defining to which vehicles this duration and distance matrix applies.
If empty, this applies to all vehicles, and there can only be a single
matrix.
Each vehicle start must match exactly one matrix, i.e. exactly one of
their start_tags
field must match the vehicle_start_tag
of a matrix
(and of that matrix only).
All matrices must have a different vehicle_start_tag
.
string vehicle_start_tag = 2;
Returns
Type | Description |
String | The vehicleStartTag.
|
getVehicleStartTagBytes()
public ByteString getVehicleStartTagBytes()
Tag defining to which vehicles this duration and distance matrix applies.
If empty, this applies to all vehicles, and there can only be a single
matrix.
Each vehicle start must match exactly one matrix, i.e. exactly one of
their start_tags
field must match the vehicle_start_tag
of a matrix
(and of that matrix only).
All matrices must have a different vehicle_start_tag
.
string vehicle_start_tag = 2;
Returns
Type | Description |
ByteString | The bytes for vehicleStartTag.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(ShipmentModel.DurationDistanceMatrix other)
public ShipmentModel.DurationDistanceMatrix.Builder mergeFrom(ShipmentModel.DurationDistanceMatrix other)
Parameter
Returns
public ShipmentModel.DurationDistanceMatrix.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public ShipmentModel.DurationDistanceMatrix.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final ShipmentModel.DurationDistanceMatrix.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
removeRows(int index)
public ShipmentModel.DurationDistanceMatrix.Builder removeRows(int index)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameter
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public ShipmentModel.DurationDistanceMatrix.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public ShipmentModel.DurationDistanceMatrix.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setRows(int index, ShipmentModel.DurationDistanceMatrix.Row value)
public ShipmentModel.DurationDistanceMatrix.Builder setRows(int index, ShipmentModel.DurationDistanceMatrix.Row value)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameters
Returns
setRows(int index, ShipmentModel.DurationDistanceMatrix.Row.Builder builderForValue)
public ShipmentModel.DurationDistanceMatrix.Builder setRows(int index, ShipmentModel.DurationDistanceMatrix.Row.Builder builderForValue)
Specifies the rows of the duration and distance matrix. It must have as
many elements as
ShipmentModel.duration_distance_matrix_src_tags.
repeated .google.cloud.optimization.v1.ShipmentModel.DurationDistanceMatrix.Row rows = 1;
Parameters
Returns
setUnknownFields(UnknownFieldSet unknownFields)
public final ShipmentModel.DurationDistanceMatrix.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
setVehicleStartTag(String value)
public ShipmentModel.DurationDistanceMatrix.Builder setVehicleStartTag(String value)
Tag defining to which vehicles this duration and distance matrix applies.
If empty, this applies to all vehicles, and there can only be a single
matrix.
Each vehicle start must match exactly one matrix, i.e. exactly one of
their start_tags
field must match the vehicle_start_tag
of a matrix
(and of that matrix only).
All matrices must have a different vehicle_start_tag
.
string vehicle_start_tag = 2;
Parameter
Name | Description |
value | String
The vehicleStartTag to set.
|
Returns
setVehicleStartTagBytes(ByteString value)
public ShipmentModel.DurationDistanceMatrix.Builder setVehicleStartTagBytes(ByteString value)
Tag defining to which vehicles this duration and distance matrix applies.
If empty, this applies to all vehicles, and there can only be a single
matrix.
Each vehicle start must match exactly one matrix, i.e. exactly one of
their start_tags
field must match the vehicle_start_tag
of a matrix
(and of that matrix only).
All matrices must have a different vehicle_start_tag
.
string vehicle_start_tag = 2;
Parameter
Name | Description |
value | ByteString
The bytes for vehicleStartTag to set.
|
Returns