Class ShipmentRoute.Visit.Builder (1.1.14)

public static final class ShipmentRoute.Visit.Builder extends GeneratedMessageV3.Builder<ShipmentRoute.Visit.Builder> implements ShipmentRoute.VisitOrBuilder

A visit performed during a route. This visit corresponds to a pickup or a delivery of a Shipment.

Protobuf type google.cloud.optimization.v1.ShipmentRoute.Visit

Static Methods

getDescriptor()

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

Methods

addAllArrivalLoads(Iterable<? extends CapacityQuantity> values)

public ShipmentRoute.Visit.Builder addAllArrivalLoads(Iterable<? extends CapacityQuantity> values)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.optimization.v1.CapacityQuantity>
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addAllDemands(Iterable<? extends CapacityQuantity> values)

public ShipmentRoute.Visit.Builder addAllDemands(Iterable<? extends CapacityQuantity> values)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.optimization.v1.CapacityQuantity>
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addArrivalLoads(CapacityQuantity value)

public ShipmentRoute.Visit.Builder addArrivalLoads(CapacityQuantity value)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
valueCapacityQuantity
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addArrivalLoads(CapacityQuantity.Builder builderForValue)

public ShipmentRoute.Visit.Builder addArrivalLoads(CapacityQuantity.Builder builderForValue)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
builderForValueCapacityQuantity.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addArrivalLoads(int index, CapacityQuantity value)

public ShipmentRoute.Visit.Builder addArrivalLoads(int index, CapacityQuantity value)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameters
NameDescription
indexint
valueCapacityQuantity
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addArrivalLoads(int index, CapacityQuantity.Builder builderForValue)

public ShipmentRoute.Visit.Builder addArrivalLoads(int index, CapacityQuantity.Builder builderForValue)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameters
NameDescription
indexint
builderForValueCapacityQuantity.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addArrivalLoadsBuilder()

public CapacityQuantity.Builder addArrivalLoadsBuilder()

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Returns
TypeDescription
CapacityQuantity.Builder

addArrivalLoadsBuilder(int index)

public CapacityQuantity.Builder addArrivalLoadsBuilder(int index)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantity.Builder

addDemands(CapacityQuantity value)

public ShipmentRoute.Visit.Builder addDemands(CapacityQuantity value)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
valueCapacityQuantity
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addDemands(CapacityQuantity.Builder builderForValue)

public ShipmentRoute.Visit.Builder addDemands(CapacityQuantity.Builder builderForValue)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
builderForValueCapacityQuantity.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addDemands(int index, CapacityQuantity value)

public ShipmentRoute.Visit.Builder addDemands(int index, CapacityQuantity value)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameters
NameDescription
indexint
valueCapacityQuantity
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addDemands(int index, CapacityQuantity.Builder builderForValue)

public ShipmentRoute.Visit.Builder addDemands(int index, CapacityQuantity.Builder builderForValue)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameters
NameDescription
indexint
builderForValueCapacityQuantity.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

addDemandsBuilder()

public CapacityQuantity.Builder addDemandsBuilder()

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Returns
TypeDescription
CapacityQuantity.Builder

addDemandsBuilder(int index)

public CapacityQuantity.Builder addDemandsBuilder(int index)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantity.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public ShipmentRoute.Visit build()
Returns
TypeDescription
ShipmentRoute.Visit

buildPartial()

public ShipmentRoute.Visit buildPartial()
Returns
TypeDescription
ShipmentRoute.Visit

clear()

public ShipmentRoute.Visit.Builder clear()
Returns
TypeDescription
ShipmentRoute.Visit.Builder
Overrides

clearArrivalLoads()

public ShipmentRoute.Visit.Builder clearArrivalLoads()

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Returns
TypeDescription
ShipmentRoute.Visit.Builder

clearDelayBeforeStart()

public ShipmentRoute.Visit.Builder clearDelayBeforeStart()

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Returns
TypeDescription
ShipmentRoute.Visit.Builder

clearDemands()

public ShipmentRoute.Visit.Builder clearDemands()

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Returns
TypeDescription
ShipmentRoute.Visit.Builder

clearDetour()

public ShipmentRoute.Visit.Builder clearDetour()

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearIsPickup()

public ShipmentRoute.Visit.Builder clearIsPickup()

If true the visit corresponds to a pickup of a Shipment. Otherwise, it corresponds to a delivery.

bool is_pickup = 2;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

clearLoadDemands()

public ShipmentRoute.Visit.Builder clearLoadDemands()
Returns
TypeDescription
ShipmentRoute.Visit.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearShipmentIndex()

public ShipmentRoute.Visit.Builder clearShipmentIndex()

Index of the shipments field in the source ShipmentModel.

int32 shipment_index = 1;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

clearShipmentLabel()

public ShipmentRoute.Visit.Builder clearShipmentLabel()

Copy of the corresponding Shipment.label, if specified in the Shipment.

string shipment_label = 7;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

clearStartTime()

public ShipmentRoute.Visit.Builder clearStartTime()

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

clearVisitLabel()

public ShipmentRoute.Visit.Builder clearVisitLabel()

Copy of the corresponding VisitRequest.label, if specified in the VisitRequest.

string visit_label = 8;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

clearVisitRequestIndex()

public ShipmentRoute.Visit.Builder clearVisitRequestIndex()

Index of VisitRequest in either the pickup or delivery field of the Shipment (see is_pickup).

int32 visit_request_index = 3;

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

clone()

public ShipmentRoute.Visit.Builder clone()
Returns
TypeDescription
ShipmentRoute.Visit.Builder
Overrides

containsLoadDemands(String key)

public boolean containsLoadDemands(String key)

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getArrivalLoads(int index)

public CapacityQuantity getArrivalLoads(int index)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantity

getArrivalLoadsBuilder(int index)

public CapacityQuantity.Builder getArrivalLoadsBuilder(int index)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantity.Builder

getArrivalLoadsBuilderList()

public List<CapacityQuantity.Builder> getArrivalLoadsBuilderList()

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Returns
TypeDescription
List<Builder>

getArrivalLoadsCount()

public int getArrivalLoadsCount()

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Returns
TypeDescription
int

getArrivalLoadsList()

public List<CapacityQuantity> getArrivalLoadsList()

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Returns
TypeDescription
List<CapacityQuantity>

getArrivalLoadsOrBuilder(int index)

public CapacityQuantityOrBuilder getArrivalLoadsOrBuilder(int index)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantityOrBuilder

getArrivalLoadsOrBuilderList()

public List<? extends CapacityQuantityOrBuilder> getArrivalLoadsOrBuilderList()

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Returns
TypeDescription
List<? extends com.google.cloud.optimization.v1.CapacityQuantityOrBuilder>

getDefaultInstanceForType()

public ShipmentRoute.Visit getDefaultInstanceForType()
Returns
TypeDescription
ShipmentRoute.Visit

getDelayBeforeStart() (deprecated)

public ShipmentRoute.Delay getDelayBeforeStart()

Deprecated. google.cloud.optimization.v1.ShipmentRoute.Visit.delay_before_start is deprecated. See google/cloud/optimization/v1/fleet_routing.proto;l=1824

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Returns
TypeDescription
ShipmentRoute.Delay

The delayBeforeStart.

getDelayBeforeStartBuilder()

public ShipmentRoute.Delay.Builder getDelayBeforeStartBuilder()

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Returns
TypeDescription
ShipmentRoute.Delay.Builder

getDelayBeforeStartOrBuilder()

public ShipmentRoute.DelayOrBuilder getDelayBeforeStartOrBuilder()

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Returns
TypeDescription
ShipmentRoute.DelayOrBuilder

getDemands(int index)

public CapacityQuantity getDemands(int index)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantity

getDemandsBuilder(int index)

public CapacityQuantity.Builder getDemandsBuilder(int index)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantity.Builder

getDemandsBuilderList()

public List<CapacityQuantity.Builder> getDemandsBuilderList()

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Returns
TypeDescription
List<Builder>

getDemandsCount()

public int getDemandsCount()

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Returns
TypeDescription
int

getDemandsList()

public List<CapacityQuantity> getDemandsList()

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Returns
TypeDescription
List<CapacityQuantity>

getDemandsOrBuilder(int index)

public CapacityQuantityOrBuilder getDemandsOrBuilder(int index)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
CapacityQuantityOrBuilder

getDemandsOrBuilderList()

public List<? extends CapacityQuantityOrBuilder> getDemandsOrBuilderList()

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Returns
TypeDescription
List<? extends com.google.cloud.optimization.v1.CapacityQuantityOrBuilder>

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDetour()

public Duration getDetour()

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Returns
TypeDescription
Duration

The detour.

getDetourBuilder()

public Duration.Builder getDetourBuilder()

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Returns
TypeDescription
Builder

getDetourOrBuilder()

public DurationOrBuilder getDetourOrBuilder()

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Returns
TypeDescription
DurationOrBuilder

getIsPickup()

public boolean getIsPickup()

If true the visit corresponds to a pickup of a Shipment. Otherwise, it corresponds to a delivery.

bool is_pickup = 2;

Returns
TypeDescription
boolean

The isPickup.

getLoadDemands()

public Map<String,Shipment.Load> getLoadDemands()

Use #getLoadDemandsMap() instead.

Returns
TypeDescription
Map<String,Load>

getLoadDemandsCount()

public int getLoadDemandsCount()

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Returns
TypeDescription
int

getLoadDemandsMap()

public Map<String,Shipment.Load> getLoadDemandsMap()

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Returns
TypeDescription
Map<String,Load>

getLoadDemandsOrDefault(String key, Shipment.Load defaultValue)

public Shipment.Load getLoadDemandsOrDefault(String key, Shipment.Load defaultValue)

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Parameters
NameDescription
keyString
defaultValueShipment.Load
Returns
TypeDescription
Shipment.Load

getLoadDemandsOrThrow(String key)

public Shipment.Load getLoadDemandsOrThrow(String key)

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Parameter
NameDescription
keyString
Returns
TypeDescription
Shipment.Load

getMutableLoadDemands()

public Map<String,Shipment.Load> getMutableLoadDemands()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,Load>

getShipmentIndex()

public int getShipmentIndex()

Index of the shipments field in the source ShipmentModel.

int32 shipment_index = 1;

Returns
TypeDescription
int

The shipmentIndex.

getShipmentLabel()

public String getShipmentLabel()

Copy of the corresponding Shipment.label, if specified in the Shipment.

string shipment_label = 7;

Returns
TypeDescription
String

The shipmentLabel.

getShipmentLabelBytes()

public ByteString getShipmentLabelBytes()

Copy of the corresponding Shipment.label, if specified in the Shipment.

string shipment_label = 7;

Returns
TypeDescription
ByteString

The bytes for shipmentLabel.

getStartTime()

public Timestamp getStartTime()

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Returns
TypeDescription
Timestamp

The startTime.

getStartTimeBuilder()

public Timestamp.Builder getStartTimeBuilder()

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Returns
TypeDescription
Builder

getStartTimeOrBuilder()

public TimestampOrBuilder getStartTimeOrBuilder()

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Returns
TypeDescription
TimestampOrBuilder

getVisitLabel()

public String getVisitLabel()

Copy of the corresponding VisitRequest.label, if specified in the VisitRequest.

string visit_label = 8;

Returns
TypeDescription
String

The visitLabel.

getVisitLabelBytes()

public ByteString getVisitLabelBytes()

Copy of the corresponding VisitRequest.label, if specified in the VisitRequest.

string visit_label = 8;

Returns
TypeDescription
ByteString

The bytes for visitLabel.

getVisitRequestIndex()

public int getVisitRequestIndex()

Index of VisitRequest in either the pickup or delivery field of the Shipment (see is_pickup).

int32 visit_request_index = 3;

Returns
TypeDescription
int

The visitRequestIndex.

hasDelayBeforeStart() (deprecated)

public boolean hasDelayBeforeStart()

Deprecated. google.cloud.optimization.v1.ShipmentRoute.Visit.delay_before_start is deprecated. See google/cloud/optimization/v1/fleet_routing.proto;l=1824

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Returns
TypeDescription
boolean

Whether the delayBeforeStart field is set.

hasDetour()

public boolean hasDetour()

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Returns
TypeDescription
boolean

Whether the detour field is set.

hasStartTime()

public boolean hasStartTime()

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Returns
TypeDescription
boolean

Whether the startTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapField(int number)

protected MapField internalGetMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

internalGetMutableMapField(int number)

protected MapField internalGetMutableMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeDelayBeforeStart(ShipmentRoute.Delay value)

public ShipmentRoute.Visit.Builder mergeDelayBeforeStart(ShipmentRoute.Delay value)

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Parameter
NameDescription
valueShipmentRoute.Delay
Returns
TypeDescription
ShipmentRoute.Visit.Builder

mergeDetour(Duration value)

public ShipmentRoute.Visit.Builder mergeDetour(Duration value)

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Parameter
NameDescription
valueDuration
Returns
TypeDescription
ShipmentRoute.Visit.Builder

mergeFrom(ShipmentRoute.Visit other)

public ShipmentRoute.Visit.Builder mergeFrom(ShipmentRoute.Visit other)
Parameter
NameDescription
otherShipmentRoute.Visit
Returns
TypeDescription
ShipmentRoute.Visit.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeStartTime(Timestamp value)

public ShipmentRoute.Visit.Builder mergeStartTime(Timestamp value)

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
ShipmentRoute.Visit.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

putAllLoadDemands(Map<String,Shipment.Load> values)

public ShipmentRoute.Visit.Builder putAllLoadDemands(Map<String,Shipment.Load> values)

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Parameter
NameDescription
valuesMap<String,Load>
Returns
TypeDescription
ShipmentRoute.Visit.Builder

putLoadDemands(String key, Shipment.Load value)

public ShipmentRoute.Visit.Builder putLoadDemands(String key, Shipment.Load value)

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Parameters
NameDescription
keyString
valueShipment.Load
Returns
TypeDescription
ShipmentRoute.Visit.Builder

removeArrivalLoads(int index)

public ShipmentRoute.Visit.Builder removeArrivalLoads(int index)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
ShipmentRoute.Visit.Builder

removeDemands(int index)

public ShipmentRoute.Visit.Builder removeDemands(int index)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
ShipmentRoute.Visit.Builder

removeLoadDemands(String key)

public ShipmentRoute.Visit.Builder removeLoadDemands(String key)

Total visit load demand as the sum of the shipment and the visit request load_demands. The values are negative if the visit is a delivery. Demands are reported for the same types as the Transition.loads (see this field).

map<string, .google.cloud.optimization.v1.Shipment.Load> load_demands = 11;

Parameter
NameDescription
keyString
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setArrivalLoads(int index, CapacityQuantity value)

public ShipmentRoute.Visit.Builder setArrivalLoads(int index, CapacityQuantity value)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameters
NameDescription
indexint
valueCapacityQuantity
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setArrivalLoads(int index, CapacityQuantity.Builder builderForValue)

public ShipmentRoute.Visit.Builder setArrivalLoads(int index, CapacityQuantity.Builder builderForValue)

Deprecated: Use [ShipmentRoute.Transition.loads][] instead. Vehicle loads upon arrival at the visit location, for each type specified in Vehicle.capacities, start_load_intervals, end_load_intervals or demands. Exception: we omit loads for quantity types unconstrained by intervals and that don't have any non-zero demand on the route.

repeated .google.cloud.optimization.v1.CapacityQuantity arrival_loads = 9 [deprecated = true];

Parameters
NameDescription
indexint
builderForValueCapacityQuantity.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setDelayBeforeStart(ShipmentRoute.Delay value)

public ShipmentRoute.Visit.Builder setDelayBeforeStart(ShipmentRoute.Delay value)

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Parameter
NameDescription
valueShipmentRoute.Delay
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setDelayBeforeStart(ShipmentRoute.Delay.Builder builderForValue)

public ShipmentRoute.Visit.Builder setDelayBeforeStart(ShipmentRoute.Delay.Builder builderForValue)

Deprecated: Use [ShipmentRoute.Transition.delay_duration][] instead.

.google.cloud.optimization.v1.ShipmentRoute.Delay delay_before_start = 10 [deprecated = true];

Parameter
NameDescription
builderForValueShipmentRoute.Delay.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setDemands(int index, CapacityQuantity value)

public ShipmentRoute.Visit.Builder setDemands(int index, CapacityQuantity value)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameters
NameDescription
indexint
valueCapacityQuantity
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setDemands(int index, CapacityQuantity.Builder builderForValue)

public ShipmentRoute.Visit.Builder setDemands(int index, CapacityQuantity.Builder builderForValue)

Deprecated: Use [Visit.load_demands][] instead.

repeated .google.cloud.optimization.v1.CapacityQuantity demands = 5 [deprecated = true];

Parameters
NameDescription
indexint
builderForValueCapacityQuantity.Builder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setDetour(Duration value)

public ShipmentRoute.Visit.Builder setDetour(Duration value)

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Parameter
NameDescription
valueDuration
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setDetour(Duration.Builder builderForValue)

public ShipmentRoute.Visit.Builder setDetour(Duration.Builder builderForValue)

Extra detour time due to the shipments visited on the route before the visit and to the potential waiting time induced by time windows. If the visit is a delivery, the detour is computed from the corresponding pickup visit and is equal to: ` start_time(delivery) - start_time(pickup)

  • (duration(pickup) + travel duration from the pickup location to the delivery location).
Otherwise, it is computed from the vehicle start_location and is equal to: start_time - vehicle_start_time - travel duration from the vehicle's start_location to the visit. `

.google.protobuf.Duration detour = 6;

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setIsPickup(boolean value)

public ShipmentRoute.Visit.Builder setIsPickup(boolean value)

If true the visit corresponds to a pickup of a Shipment. Otherwise, it corresponds to a delivery.

bool is_pickup = 2;

Parameter
NameDescription
valueboolean

The isPickup to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

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

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

setShipmentIndex(int value)

public ShipmentRoute.Visit.Builder setShipmentIndex(int value)

Index of the shipments field in the source ShipmentModel.

int32 shipment_index = 1;

Parameter
NameDescription
valueint

The shipmentIndex to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

setShipmentLabel(String value)

public ShipmentRoute.Visit.Builder setShipmentLabel(String value)

Copy of the corresponding Shipment.label, if specified in the Shipment.

string shipment_label = 7;

Parameter
NameDescription
valueString

The shipmentLabel to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

setShipmentLabelBytes(ByteString value)

public ShipmentRoute.Visit.Builder setShipmentLabelBytes(ByteString value)

Copy of the corresponding Shipment.label, if specified in the Shipment.

string shipment_label = 7;

Parameter
NameDescription
valueByteString

The bytes for shipmentLabel to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

setStartTime(Timestamp value)

public ShipmentRoute.Visit.Builder setStartTime(Timestamp value)

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setStartTime(Timestamp.Builder builderForValue)

public ShipmentRoute.Visit.Builder setStartTime(Timestamp.Builder builderForValue)

Time at which the visit starts. Note that the vehicle may arrive earlier than this at the visit location. Times are consistent with the ShipmentModel.

.google.protobuf.Timestamp start_time = 4;

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
ShipmentRoute.Visit.Builder

setUnknownFields(UnknownFieldSet unknownFields)

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

setVisitLabel(String value)

public ShipmentRoute.Visit.Builder setVisitLabel(String value)

Copy of the corresponding VisitRequest.label, if specified in the VisitRequest.

string visit_label = 8;

Parameter
NameDescription
valueString

The visitLabel to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

setVisitLabelBytes(ByteString value)

public ShipmentRoute.Visit.Builder setVisitLabelBytes(ByteString value)

Copy of the corresponding VisitRequest.label, if specified in the VisitRequest.

string visit_label = 8;

Parameter
NameDescription
valueByteString

The bytes for visitLabel to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.

setVisitRequestIndex(int value)

public ShipmentRoute.Visit.Builder setVisitRequestIndex(int value)

Index of VisitRequest in either the pickup or delivery field of the Shipment (see is_pickup).

int32 visit_request_index = 3;

Parameter
NameDescription
valueint

The visitRequestIndex to set.

Returns
TypeDescription
ShipmentRoute.Visit.Builder

This builder for chaining.