Google Maps Route Optimization V1 Client - Class AggregatedMetrics (0.2.0)

Reference documentation and code samples for the Google Maps Route 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.maps.routeoptimization.v1.AggregatedMetrics

Namespace

Google \ Maps \ RouteOptimization \ 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: <xref uid="\Google\Maps\RouteOptimization\V1\ShipmentRoute::getVehicleEndTime()">ShipmentRoute.vehicle_end_time</xref> - <xref uid="\Google\Maps\RouteOptimization\V1\ShipmentRoute::getVehicleStartTime()">ShipmentRoute.vehicle_start_time</xref>

↳ 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.

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:

<xref uid="\Google\Maps\RouteOptimization\V1\ShipmentRoute::getVehicleEndTime()">ShipmentRoute.vehicle_end_time</xref>
-
<xref uid="\Google\Maps\RouteOptimization\V1\ShipmentRoute::getVehicleStartTime()">ShipmentRoute.vehicle_start_time</xref>
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:

<xref uid="\Google\Maps\RouteOptimization\V1\ShipmentRoute::getVehicleEndTime()">ShipmentRoute.vehicle_end_time</xref>
-
<xref uid="\Google\Maps\RouteOptimization\V1\ShipmentRoute::getVehicleStartTime()">ShipmentRoute.vehicle_start_time</xref>
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