Google Cloud Optimization V1 Client - Class BreakRule (0.2.0)

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

Deprecated: Use top level BreakRule instead.

Rules to generate time breaks for a vehicle (e.g. lunch breaks). A break is a contiguous period of time during which the vehicle remains idle at its current position and cannot perform any visit. A break may occur:

  • during the travel between two visits (which includes the time right before or right after a visit, but not in the middle of a visit), in which case it extends the corresponding transit time between the visits
  • before the vehicle start (the vehicle may not start in the middle of a break), in which case it does not affect the vehicle start time.
  • after the vehicle end (ditto, with the vehicle end time).

Generated from protobuf message google.cloud.optimization.v1.ShipmentModel.BreakRule

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ break_requests array<Google\Cloud\Optimization\V1\ShipmentModel\BreakRule\BreakRequest>

Sequence of breaks. See the BreakRequest message.

↳ frequency_constraints array<Google\Cloud\Optimization\V1\ShipmentModel\BreakRule\FrequencyConstraint>

Several FrequencyConstraint may apply. They must all be satisfied by the BreakRequests of this BreakRule. See FrequencyConstraint.

getBreakRequests

Sequence of breaks. See the BreakRequest message.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setBreakRequests

Sequence of breaks. See the BreakRequest message.

Parameter
NameDescription
var array<Google\Cloud\Optimization\V1\ShipmentModel\BreakRule\BreakRequest>
Returns
TypeDescription
$this

getFrequencyConstraints

Several FrequencyConstraint may apply. They must all be satisfied by the BreakRequests of this BreakRule. See FrequencyConstraint.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setFrequencyConstraints

Several FrequencyConstraint may apply. They must all be satisfied by the BreakRequests of this BreakRule. See FrequencyConstraint.

Parameter
NameDescription
var array<Google\Cloud\Optimization\V1\ShipmentModel\BreakRule\FrequencyConstraint>
Returns
TypeDescription
$this