Class AggregatedMetrics.Builder (1.40.0)

public static final class AggregatedMetrics.Builder extends GeneratedMessageV3.Builder<AggregatedMetrics.Builder> implements AggregatedMetricsOrBuilder

Aggregated metrics for ShipmentRoute (resp. for OptimizeToursResponse over all Transition and/or Visit (resp. over all ShipmentRoute) elements.

Protobuf type google.cloud.optimization.v1.AggregatedMetrics

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public AggregatedMetrics.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
AggregatedMetrics.Builder
Overrides

build()

public AggregatedMetrics build()
Returns
Type Description
AggregatedMetrics

buildPartial()

public AggregatedMetrics buildPartial()
Returns
Type Description
AggregatedMetrics

clear()

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

clearBreakDuration()

public AggregatedMetrics.Builder clearBreakDuration()

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Returns
Type Description
AggregatedMetrics.Builder

clearCosts() (deprecated)

public AggregatedMetrics.Builder clearCosts()
Returns
Type Description
AggregatedMetrics.Builder

clearDelayDuration()

public AggregatedMetrics.Builder clearDelayDuration()

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Returns
Type Description
AggregatedMetrics.Builder

clearField(Descriptors.FieldDescriptor field)

public AggregatedMetrics.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
AggregatedMetrics.Builder
Overrides

clearMaxLoads()

public AggregatedMetrics.Builder clearMaxLoads()
Returns
Type Description
AggregatedMetrics.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public AggregatedMetrics.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
AggregatedMetrics.Builder
Overrides

clearPerformedShipmentCount()

public AggregatedMetrics.Builder clearPerformedShipmentCount()

Number of shipments performed. Note that a pickup and delivery pair only counts once.

int32 performed_shipment_count = 1;

Returns
Type Description
AggregatedMetrics.Builder

This builder for chaining.

clearTotalCost() (deprecated)

public AggregatedMetrics.Builder clearTotalCost()

Deprecated. google.cloud.optimization.v1.AggregatedMetrics.total_cost is deprecated. See google/cloud/optimization/v1/fleet_routing.proto;l=2381

Deprecated: Use ShipmentRoute.route_total_cost and OptimizeToursResponse.Metrics.total_cost instead.

double total_cost = 11 [deprecated = true];

Returns
Type Description
AggregatedMetrics.Builder

This builder for chaining.

clearTotalDuration()

public AggregatedMetrics.Builder clearTotalDuration()

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Returns
Type Description
AggregatedMetrics.Builder

clearTravelDistanceMeters()

public AggregatedMetrics.Builder clearTravelDistanceMeters()

Total travel distance for a route or a solution.

double travel_distance_meters = 8;

Returns
Type Description
AggregatedMetrics.Builder

This builder for chaining.

clearTravelDuration()

public AggregatedMetrics.Builder clearTravelDuration()

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Returns
Type Description
AggregatedMetrics.Builder

clearVisitDuration()

public AggregatedMetrics.Builder clearVisitDuration()

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Returns
Type Description
AggregatedMetrics.Builder

clearWaitDuration()

public AggregatedMetrics.Builder clearWaitDuration()

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Returns
Type Description
AggregatedMetrics.Builder

clone()

public AggregatedMetrics.Builder clone()
Returns
Type Description
AggregatedMetrics.Builder
Overrides

containsCosts(String key) (deprecated)

public boolean containsCosts(String key)

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Parameter
Name Description
key String
Returns
Type Description
boolean

containsMaxLoads(String key)

public boolean containsMaxLoads(String key)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameter
Name Description
key String
Returns
Type Description
boolean

getBreakDuration()

public Duration getBreakDuration()

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Returns
Type Description
Duration

The breakDuration.

getBreakDurationBuilder()

public Duration.Builder getBreakDurationBuilder()

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Returns
Type Description
Builder

getBreakDurationOrBuilder()

public DurationOrBuilder getBreakDurationOrBuilder()

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Returns
Type Description
DurationOrBuilder

getCosts() (deprecated)

public Map<String,Double> getCosts()

Use #getCostsMap() instead.

Returns
Type Description
Map<String,Double>

getCostsCount() (deprecated)

public int getCostsCount()

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Returns
Type Description
int

getCostsMap() (deprecated)

public Map<String,Double> getCostsMap()

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Returns
Type Description
Map<String,Double>

getCostsOrDefault(String key, double defaultValue) (deprecated)

public double getCostsOrDefault(String key, double defaultValue)

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Parameters
Name Description
key String
defaultValue double
Returns
Type Description
double

getCostsOrThrow(String key) (deprecated)

public double getCostsOrThrow(String key)

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Parameter
Name Description
key String
Returns
Type Description
double

getDefaultInstanceForType()

public AggregatedMetrics getDefaultInstanceForType()
Returns
Type Description
AggregatedMetrics

getDelayDuration()

public Duration getDelayDuration()

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Returns
Type Description
Duration

The delayDuration.

getDelayDurationBuilder()

public Duration.Builder getDelayDurationBuilder()

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Returns
Type Description
Builder

getDelayDurationOrBuilder()

public DurationOrBuilder getDelayDurationOrBuilder()

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Returns
Type Description
DurationOrBuilder

getDescriptorForType()

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

getMaxLoads() (deprecated)

public Map<String,ShipmentRoute.VehicleLoad> getMaxLoads()

Use #getMaxLoadsMap() instead.

Returns
Type Description
Map<String,VehicleLoad>

getMaxLoadsCount()

public int getMaxLoadsCount()

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Returns
Type Description
int

getMaxLoadsMap()

public Map<String,ShipmentRoute.VehicleLoad> getMaxLoadsMap()

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Returns
Type Description
Map<String,VehicleLoad>

getMaxLoadsOrDefault(String key, ShipmentRoute.VehicleLoad defaultValue)

public ShipmentRoute.VehicleLoad getMaxLoadsOrDefault(String key, ShipmentRoute.VehicleLoad defaultValue)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameters
Name Description
key String
defaultValue ShipmentRoute.VehicleLoad
Returns
Type Description
ShipmentRoute.VehicleLoad

getMaxLoadsOrThrow(String key)

public ShipmentRoute.VehicleLoad getMaxLoadsOrThrow(String key)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameter
Name Description
key String
Returns
Type Description
ShipmentRoute.VehicleLoad

getMutableCosts() (deprecated)

public Map<String,Double> getMutableCosts()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,Double>

getMutableMaxLoads() (deprecated)

public Map<String,ShipmentRoute.VehicleLoad> getMutableMaxLoads()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,VehicleLoad>

getPerformedShipmentCount()

public int getPerformedShipmentCount()

Number of shipments performed. Note that a pickup and delivery pair only counts once.

int32 performed_shipment_count = 1;

Returns
Type Description
int

The performedShipmentCount.

getTotalCost() (deprecated)

public double getTotalCost()

Deprecated. google.cloud.optimization.v1.AggregatedMetrics.total_cost is deprecated. See google/cloud/optimization/v1/fleet_routing.proto;l=2381

Deprecated: Use ShipmentRoute.route_total_cost and OptimizeToursResponse.Metrics.total_cost instead.

double total_cost = 11 [deprecated = true];

Returns
Type Description
double

The totalCost.

getTotalDuration()

public Duration getTotalDuration()

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Returns
Type Description
Duration

The totalDuration.

getTotalDurationBuilder()

public Duration.Builder getTotalDurationBuilder()

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Returns
Type Description
Builder

getTotalDurationOrBuilder()

public DurationOrBuilder getTotalDurationOrBuilder()

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Returns
Type Description
DurationOrBuilder

getTravelDistanceMeters()

public double getTravelDistanceMeters()

Total travel distance for a route or a solution.

double travel_distance_meters = 8;

Returns
Type Description
double

The travelDistanceMeters.

getTravelDuration()

public Duration getTravelDuration()

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Returns
Type Description
Duration

The travelDuration.

getTravelDurationBuilder()

public Duration.Builder getTravelDurationBuilder()

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Returns
Type Description
Builder

getTravelDurationOrBuilder()

public DurationOrBuilder getTravelDurationOrBuilder()

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Returns
Type Description
DurationOrBuilder

getVisitDuration()

public Duration getVisitDuration()

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Returns
Type Description
Duration

The visitDuration.

getVisitDurationBuilder()

public Duration.Builder getVisitDurationBuilder()

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Returns
Type Description
Builder

getVisitDurationOrBuilder()

public DurationOrBuilder getVisitDurationOrBuilder()

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Returns
Type Description
DurationOrBuilder

getWaitDuration()

public Duration getWaitDuration()

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Returns
Type Description
Duration

The waitDuration.

getWaitDurationBuilder()

public Duration.Builder getWaitDurationBuilder()

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Returns
Type Description
Builder

getWaitDurationOrBuilder()

public DurationOrBuilder getWaitDurationOrBuilder()

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Returns
Type Description
DurationOrBuilder

hasBreakDuration()

public boolean hasBreakDuration()

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Returns
Type Description
boolean

Whether the breakDuration field is set.

hasDelayDuration()

public boolean hasDelayDuration()

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Returns
Type Description
boolean

Whether the delayDuration field is set.

hasTotalDuration()

public boolean hasTotalDuration()

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Returns
Type Description
boolean

Whether the totalDuration field is set.

hasTravelDuration()

public boolean hasTravelDuration()

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Returns
Type Description
boolean

Whether the travelDuration field is set.

hasVisitDuration()

public boolean hasVisitDuration()

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Returns
Type Description
boolean

Whether the visitDuration field is set.

hasWaitDuration()

public boolean hasWaitDuration()

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Returns
Type Description
boolean

Whether the waitDuration field is set.

internalGetFieldAccessorTable()

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

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeBreakDuration(Duration value)

public AggregatedMetrics.Builder mergeBreakDuration(Duration value)

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

mergeDelayDuration(Duration value)

public AggregatedMetrics.Builder mergeDelayDuration(Duration value)

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

mergeFrom(AggregatedMetrics other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeTotalDuration(Duration value)

public AggregatedMetrics.Builder mergeTotalDuration(Duration value)

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

mergeTravelDuration(Duration value)

public AggregatedMetrics.Builder mergeTravelDuration(Duration value)

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final AggregatedMetrics.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
AggregatedMetrics.Builder
Overrides

mergeVisitDuration(Duration value)

public AggregatedMetrics.Builder mergeVisitDuration(Duration value)

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

mergeWaitDuration(Duration value)

public AggregatedMetrics.Builder mergeWaitDuration(Duration value)

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

putAllCosts(Map<String,Double> values) (deprecated)

public AggregatedMetrics.Builder putAllCosts(Map<String,Double> values)

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Parameter
Name Description
values Map<String,Double>
Returns
Type Description
AggregatedMetrics.Builder

putAllMaxLoads(Map<String,ShipmentRoute.VehicleLoad> values)

public AggregatedMetrics.Builder putAllMaxLoads(Map<String,ShipmentRoute.VehicleLoad> values)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameter
Name Description
values Map<String,VehicleLoad>
Returns
Type Description
AggregatedMetrics.Builder

putCosts(String key, double value) (deprecated)

public AggregatedMetrics.Builder putCosts(String key, double value)

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Parameters
Name Description
key String
value double
Returns
Type Description
AggregatedMetrics.Builder

putMaxLoads(String key, ShipmentRoute.VehicleLoad value)

public AggregatedMetrics.Builder putMaxLoads(String key, ShipmentRoute.VehicleLoad value)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameters
Name Description
key String
value ShipmentRoute.VehicleLoad
Returns
Type Description
AggregatedMetrics.Builder

putMaxLoadsBuilderIfAbsent(String key)

public ShipmentRoute.VehicleLoad.Builder putMaxLoadsBuilderIfAbsent(String key)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameter
Name Description
key String
Returns
Type Description
ShipmentRoute.VehicleLoad.Builder

removeCosts(String key) (deprecated)

public AggregatedMetrics.Builder removeCosts(String key)

Deprecated: Use ShipmentRoute.route_costs and OptimizeToursResponse.Metrics.costs instead.

map<string, double> costs = 10 [deprecated = true];

Parameter
Name Description
key String
Returns
Type Description
AggregatedMetrics.Builder

removeMaxLoads(String key)

public AggregatedMetrics.Builder removeMaxLoads(String key)

Maximum load achieved over the entire route (resp. solution), for each of the quantities on this route (resp. solution), computed as the maximum over all Transition.vehicle_loads (resp. ShipmentRoute.metrics.max_loads.

map<string, .google.cloud.optimization.v1.ShipmentRoute.VehicleLoad> max_loads = 9;

Parameter
Name Description
key String
Returns
Type Description
AggregatedMetrics.Builder

setBreakDuration(Duration value)

public AggregatedMetrics.Builder setBreakDuration(Duration value)

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

setBreakDuration(Duration.Builder builderForValue)

public AggregatedMetrics.Builder setBreakDuration(Duration.Builder builderForValue)

Total break duration for a route or a solution.

.google.protobuf.Duration break_duration = 5;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
AggregatedMetrics.Builder

setDelayDuration(Duration value)

public AggregatedMetrics.Builder setDelayDuration(Duration value)

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

setDelayDuration(Duration.Builder builderForValue)

public AggregatedMetrics.Builder setDelayDuration(Duration.Builder builderForValue)

Total delay duration for a route or a solution.

.google.protobuf.Duration delay_duration = 4;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
AggregatedMetrics.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public AggregatedMetrics.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
AggregatedMetrics.Builder
Overrides

setPerformedShipmentCount(int value)

public AggregatedMetrics.Builder setPerformedShipmentCount(int value)

Number of shipments performed. Note that a pickup and delivery pair only counts once.

int32 performed_shipment_count = 1;

Parameter
Name Description
value int

The performedShipmentCount to set.

Returns
Type Description
AggregatedMetrics.Builder

This builder for chaining.

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

public AggregatedMetrics.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
AggregatedMetrics.Builder
Overrides

setTotalCost(double value) (deprecated)

public AggregatedMetrics.Builder setTotalCost(double value)

Deprecated. google.cloud.optimization.v1.AggregatedMetrics.total_cost is deprecated. See google/cloud/optimization/v1/fleet_routing.proto;l=2381

Deprecated: Use ShipmentRoute.route_total_cost and OptimizeToursResponse.Metrics.total_cost instead.

double total_cost = 11 [deprecated = true];

Parameter
Name Description
value double

The totalCost to set.

Returns
Type Description
AggregatedMetrics.Builder

This builder for chaining.

setTotalDuration(Duration value)

public AggregatedMetrics.Builder setTotalDuration(Duration value)

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

setTotalDuration(Duration.Builder builderForValue)

public AggregatedMetrics.Builder setTotalDuration(Duration.Builder builderForValue)

The total duration should be equal to the sum of all durations above. For routes, it also corresponds to: ShipmentRoute.vehicle_end_time - ShipmentRoute.vehicle_start_time

.google.protobuf.Duration total_duration = 7;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
AggregatedMetrics.Builder

setTravelDistanceMeters(double value)

public AggregatedMetrics.Builder setTravelDistanceMeters(double value)

Total travel distance for a route or a solution.

double travel_distance_meters = 8;

Parameter
Name Description
value double

The travelDistanceMeters to set.

Returns
Type Description
AggregatedMetrics.Builder

This builder for chaining.

setTravelDuration(Duration value)

public AggregatedMetrics.Builder setTravelDuration(Duration value)

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

setTravelDuration(Duration.Builder builderForValue)

public AggregatedMetrics.Builder setTravelDuration(Duration.Builder builderForValue)

Total travel duration for a route or a solution.

.google.protobuf.Duration travel_duration = 2;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
AggregatedMetrics.Builder

setUnknownFields(UnknownFieldSet unknownFields)

public final AggregatedMetrics.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
AggregatedMetrics.Builder
Overrides

setVisitDuration(Duration value)

public AggregatedMetrics.Builder setVisitDuration(Duration value)

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

setVisitDuration(Duration.Builder builderForValue)

public AggregatedMetrics.Builder setVisitDuration(Duration.Builder builderForValue)

Total visit duration for a route or a solution.

.google.protobuf.Duration visit_duration = 6;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
AggregatedMetrics.Builder

setWaitDuration(Duration value)

public AggregatedMetrics.Builder setWaitDuration(Duration value)

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Parameter
Name Description
value Duration
Returns
Type Description
AggregatedMetrics.Builder

setWaitDuration(Duration.Builder builderForValue)

public AggregatedMetrics.Builder setWaitDuration(Duration.Builder builderForValue)

Total wait duration for a route or a solution.

.google.protobuf.Duration wait_duration = 3;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
AggregatedMetrics.Builder