Google Cloud Optimization V1 Client - Class AggregatedMetrics (0.6.5)

Reference documentation and code samples for the Google Cloud Optimization V1 Client class AggregatedMetrics.

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

Generated from protobuf message google.cloud.optimization.v1.AggregatedMetrics

Namespace

Google \ Cloud \ Optimization \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ performed_shipment_count int

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

↳ travel_duration Google\Protobuf\Duration

Total travel duration for a route or a solution.

↳ wait_duration Google\Protobuf\Duration

Total wait duration for a route or a solution.

↳ delay_duration Google\Protobuf\Duration

Total delay duration for a route or a solution.

↳ break_duration Google\Protobuf\Duration

Total break duration for a route or a solution.

↳ visit_duration Google\Protobuf\Duration

Total visit duration for a route or a solution.

↳ total_duration Google\Protobuf\Duration

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

↳ travel_distance_meters float

Total travel distance for a route or a solution.

↳ max_loads array|Google\Protobuf\Internal\MapField

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.

↳ costs array|Google\Protobuf\Internal\MapField

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

↳ total_cost float

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

getPerformedShipmentCount

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

Returns
Type Description
int

setPerformedShipmentCount

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

Parameter
Name Description
var int
Returns
Type Description
$this

getTravelDuration

Total travel duration for a route or a solution.

Returns
Type Description
Google\Protobuf\Duration|null

hasTravelDuration

clearTravelDuration

setTravelDuration

Total travel duration for a route or a solution.

Parameter
Name Description
var Google\Protobuf\Duration
Returns
Type Description
$this

getWaitDuration

Total wait duration for a route or a solution.

Returns
Type Description
Google\Protobuf\Duration|null

hasWaitDuration

clearWaitDuration

setWaitDuration

Total wait duration for a route or a solution.

Parameter
Name Description
var Google\Protobuf\Duration
Returns
Type Description
$this

getDelayDuration

Total delay duration for a route or a solution.

Returns
Type Description
Google\Protobuf\Duration|null

hasDelayDuration

clearDelayDuration

setDelayDuration

Total delay duration for a route or a solution.

Parameter
Name Description
var Google\Protobuf\Duration
Returns
Type Description
$this

getBreakDuration

Total break duration for a route or a solution.

Returns
Type Description
Google\Protobuf\Duration|null

hasBreakDuration

clearBreakDuration

setBreakDuration

Total break duration for a route or a solution.

Parameter
Name Description
var Google\Protobuf\Duration
Returns
Type Description
$this

getVisitDuration

Total visit duration for a route or a solution.

Returns
Type Description
Google\Protobuf\Duration|null

hasVisitDuration

clearVisitDuration

setVisitDuration

Total visit duration for a route or a solution.

Parameter
Name Description
var Google\Protobuf\Duration
Returns
Type Description
$this

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

Returns
Type Description
Google\Protobuf\Duration|null

hasTotalDuration

clearTotalDuration

setTotalDuration

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

Parameter
Name Description
var Google\Protobuf\Duration
Returns
Type Description
$this

getTravelDistanceMeters

Total travel distance for a route or a solution.

Returns
Type Description
float

setTravelDistanceMeters

Total travel distance for a route or a solution.

Parameter
Name Description
var float
Returns
Type Description
$this

getMaxLoads

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.

Returns
Type Description
Google\Protobuf\Internal\MapField

setMaxLoads

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.

Parameter
Name Description
var array|Google\Protobuf\Internal\MapField
Returns
Type Description
$this

getCosts

Returns
Type Description
Google\Protobuf\Internal\MapField

setCosts

Parameter
Name Description
var array|Google\Protobuf\Internal\MapField
Returns
Type Description
$this

getTotalCost

Returns
Type Description
float

setTotalCost

Parameter
Name Description
var float
Returns
Type Description
$this