<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/maps/fleetengine/v1/trip_api.proto

namespace Google\Maps\FleetEngine\V1;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * GetTrip request message.
 *
 * Generated from protobuf message <code>maps.fleetengine.v1.GetTripRequest</code>
 */
class GetTripRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * The standard Fleet Engine request header.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.RequestHeader header = 1;</code>
     */
    protected $header = null;
    /**
     * Required. Must be in the format `providers/{provider}/trips/{trip}`.
     * The provider must be the Project ID (for example, `sample-cloud-project`)
     * of the Google Cloud Project of which the service account making
     * this call is a member.
     *
     * Generated from protobuf field <code>string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     */
    protected $name = '';
    /**
     * The subset of Trip fields that should be returned and their interpretation.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.TripView view = 11;</code>
     */
    protected $view = 0;
    /**
     * Indicates the minimum timestamp (exclusive) for which `Trip.route` or
     * `Trip.current_route_segment` data are retrieved. If route data are
     * unchanged since this timestamp, the route field is not set in the response.
     * If a minimum is unspecified, the route data are always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp current_route_segment_version = 6;</code>
     */
    protected $current_route_segment_version = null;
    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.remaining_waypoints` are retrieved. If they are unchanged since this
     * timestamp, the `remaining_waypoints` are not set in the response. If this
     * field is unspecified, `remaining_waypoints` is always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp remaining_waypoints_version = 7;</code>
     */
    protected $remaining_waypoints_version = null;
    /**
     * The returned current route format, `LAT_LNG_LIST_TYPE` (in `Trip.route`),
     * or `ENCODED_POLYLINE_TYPE` (in `Trip.current_route_segment`). The default
     * is `LAT_LNG_LIST_TYPE`.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.PolylineFormatType route_format_type = 8;</code>
     */
    protected $route_format_type = 0;
    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.current_route_segment_traffic` is retrieved. If traffic data are
     * unchanged since this timestamp, the `current_route_segment_traffic` field
     * is not set in the response. If a minimum is unspecified, the traffic data
     * are always retrieved. Note that traffic is only available for On-Demand
     * Rides and Deliveries Solution customers.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp current_route_segment_traffic_version = 9;</code>
     */
    protected $current_route_segment_traffic_version = null;
    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.remaining_waypoints.traffic_to_waypoint` and
     * `Trip.remaining_waypoints.path_to_waypoint` data are retrieved. If data are
     * unchanged since this timestamp, the fields above are
     * not set in the response. If `remaining_waypoints_route_version` is
     * unspecified, traffic and path are always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp remaining_waypoints_route_version = 10;</code>
     */
    protected $remaining_waypoints_route_version = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Maps\FleetEngine\V1\RequestHeader $header
     *           The standard Fleet Engine request header.
     *     @type string $name
     *           Required. Must be in the format `providers/{provider}/trips/{trip}`.
     *           The provider must be the Project ID (for example, `sample-cloud-project`)
     *           of the Google Cloud Project of which the service account making
     *           this call is a member.
     *     @type int $view
     *           The subset of Trip fields that should be returned and their interpretation.
     *     @type \Google\Protobuf\Timestamp $current_route_segment_version
     *           Indicates the minimum timestamp (exclusive) for which `Trip.route` or
     *           `Trip.current_route_segment` data are retrieved. If route data are
     *           unchanged since this timestamp, the route field is not set in the response.
     *           If a minimum is unspecified, the route data are always retrieved.
     *     @type \Google\Protobuf\Timestamp $remaining_waypoints_version
     *           Indicates the minimum timestamp (exclusive) for which
     *           `Trip.remaining_waypoints` are retrieved. If they are unchanged since this
     *           timestamp, the `remaining_waypoints` are not set in the response. If this
     *           field is unspecified, `remaining_waypoints` is always retrieved.
     *     @type int $route_format_type
     *           The returned current route format, `LAT_LNG_LIST_TYPE` (in `Trip.route`),
     *           or `ENCODED_POLYLINE_TYPE` (in `Trip.current_route_segment`). The default
     *           is `LAT_LNG_LIST_TYPE`.
     *     @type \Google\Protobuf\Timestamp $current_route_segment_traffic_version
     *           Indicates the minimum timestamp (exclusive) for which
     *           `Trip.current_route_segment_traffic` is retrieved. If traffic data are
     *           unchanged since this timestamp, the `current_route_segment_traffic` field
     *           is not set in the response. If a minimum is unspecified, the traffic data
     *           are always retrieved. Note that traffic is only available for On-Demand
     *           Rides and Deliveries Solution customers.
     *     @type \Google\Protobuf\Timestamp $remaining_waypoints_route_version
     *           Indicates the minimum timestamp (exclusive) for which
     *           `Trip.remaining_waypoints.traffic_to_waypoint` and
     *           `Trip.remaining_waypoints.path_to_waypoint` data are retrieved. If data are
     *           unchanged since this timestamp, the fields above are
     *           not set in the response. If `remaining_waypoints_route_version` is
     *           unspecified, traffic and path are always retrieved.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Maps\Fleetengine\V1\TripApi::initOnce();
        parent::__construct($data);
    }

    /**
     * The standard Fleet Engine request header.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.RequestHeader header = 1;</code>
     * @return \Google\Maps\FleetEngine\V1\RequestHeader|null
     */
    public function getHeader()
    {
        return $this->header;
    }

    public function hasHeader()
    {
        return isset($this->header);
    }

    public function clearHeader()
    {
        unset($this->header);
    }

    /**
     * The standard Fleet Engine request header.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.RequestHeader header = 1;</code>
     * @param \Google\Maps\FleetEngine\V1\RequestHeader $var
     * @return $this
     */
    public function setHeader($var)
    {
        GPBUtil::checkMessage($var, \Google\Maps\FleetEngine\V1\RequestHeader::class);
        $this->header = $var;

        return $this;
    }

    /**
     * Required. Must be in the format `providers/{provider}/trips/{trip}`.
     * The provider must be the Project ID (for example, `sample-cloud-project`)
     * of the Google Cloud Project of which the service account making
     * this call is a member.
     *
     * Generated from protobuf field <code>string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Required. Must be in the format `providers/{provider}/trips/{trip}`.
     * The provider must be the Project ID (for example, `sample-cloud-project`)
     * of the Google Cloud Project of which the service account making
     * this call is a member.
     *
     * Generated from protobuf field <code>string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * The subset of Trip fields that should be returned and their interpretation.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.TripView view = 11;</code>
     * @return int
     */
    public function getView()
    {
        return $this->view;
    }

    /**
     * The subset of Trip fields that should be returned and their interpretation.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.TripView view = 11;</code>
     * @param int $var
     * @return $this
     */
    public function setView($var)
    {
        GPBUtil::checkEnum($var, \Google\Maps\FleetEngine\V1\TripView::class);
        $this->view = $var;

        return $this;
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which `Trip.route` or
     * `Trip.current_route_segment` data are retrieved. If route data are
     * unchanged since this timestamp, the route field is not set in the response.
     * If a minimum is unspecified, the route data are always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp current_route_segment_version = 6;</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getCurrentRouteSegmentVersion()
    {
        return $this->current_route_segment_version;
    }

    public function hasCurrentRouteSegmentVersion()
    {
        return isset($this->current_route_segment_version);
    }

    public function clearCurrentRouteSegmentVersion()
    {
        unset($this->current_route_segment_version);
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which `Trip.route` or
     * `Trip.current_route_segment` data are retrieved. If route data are
     * unchanged since this timestamp, the route field is not set in the response.
     * If a minimum is unspecified, the route data are always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp current_route_segment_version = 6;</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setCurrentRouteSegmentVersion($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->current_route_segment_version = $var;

        return $this;
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.remaining_waypoints` are retrieved. If they are unchanged since this
     * timestamp, the `remaining_waypoints` are not set in the response. If this
     * field is unspecified, `remaining_waypoints` is always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp remaining_waypoints_version = 7;</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getRemainingWaypointsVersion()
    {
        return $this->remaining_waypoints_version;
    }

    public function hasRemainingWaypointsVersion()
    {
        return isset($this->remaining_waypoints_version);
    }

    public function clearRemainingWaypointsVersion()
    {
        unset($this->remaining_waypoints_version);
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.remaining_waypoints` are retrieved. If they are unchanged since this
     * timestamp, the `remaining_waypoints` are not set in the response. If this
     * field is unspecified, `remaining_waypoints` is always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp remaining_waypoints_version = 7;</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setRemainingWaypointsVersion($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->remaining_waypoints_version = $var;

        return $this;
    }

    /**
     * The returned current route format, `LAT_LNG_LIST_TYPE` (in `Trip.route`),
     * or `ENCODED_POLYLINE_TYPE` (in `Trip.current_route_segment`). The default
     * is `LAT_LNG_LIST_TYPE`.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.PolylineFormatType route_format_type = 8;</code>
     * @return int
     */
    public function getRouteFormatType()
    {
        return $this->route_format_type;
    }

    /**
     * The returned current route format, `LAT_LNG_LIST_TYPE` (in `Trip.route`),
     * or `ENCODED_POLYLINE_TYPE` (in `Trip.current_route_segment`). The default
     * is `LAT_LNG_LIST_TYPE`.
     *
     * Generated from protobuf field <code>.maps.fleetengine.v1.PolylineFormatType route_format_type = 8;</code>
     * @param int $var
     * @return $this
     */
    public function setRouteFormatType($var)
    {
        GPBUtil::checkEnum($var, \Google\Maps\FleetEngine\V1\PolylineFormatType::class);
        $this->route_format_type = $var;

        return $this;
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.current_route_segment_traffic` is retrieved. If traffic data are
     * unchanged since this timestamp, the `current_route_segment_traffic` field
     * is not set in the response. If a minimum is unspecified, the traffic data
     * are always retrieved. Note that traffic is only available for On-Demand
     * Rides and Deliveries Solution customers.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp current_route_segment_traffic_version = 9;</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getCurrentRouteSegmentTrafficVersion()
    {
        return $this->current_route_segment_traffic_version;
    }

    public function hasCurrentRouteSegmentTrafficVersion()
    {
        return isset($this->current_route_segment_traffic_version);
    }

    public function clearCurrentRouteSegmentTrafficVersion()
    {
        unset($this->current_route_segment_traffic_version);
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.current_route_segment_traffic` is retrieved. If traffic data are
     * unchanged since this timestamp, the `current_route_segment_traffic` field
     * is not set in the response. If a minimum is unspecified, the traffic data
     * are always retrieved. Note that traffic is only available for On-Demand
     * Rides and Deliveries Solution customers.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp current_route_segment_traffic_version = 9;</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setCurrentRouteSegmentTrafficVersion($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->current_route_segment_traffic_version = $var;

        return $this;
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.remaining_waypoints.traffic_to_waypoint` and
     * `Trip.remaining_waypoints.path_to_waypoint` data are retrieved. If data are
     * unchanged since this timestamp, the fields above are
     * not set in the response. If `remaining_waypoints_route_version` is
     * unspecified, traffic and path are always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp remaining_waypoints_route_version = 10;</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getRemainingWaypointsRouteVersion()
    {
        return $this->remaining_waypoints_route_version;
    }

    public function hasRemainingWaypointsRouteVersion()
    {
        return isset($this->remaining_waypoints_route_version);
    }

    public function clearRemainingWaypointsRouteVersion()
    {
        unset($this->remaining_waypoints_route_version);
    }

    /**
     * Indicates the minimum timestamp (exclusive) for which
     * `Trip.remaining_waypoints.traffic_to_waypoint` and
     * `Trip.remaining_waypoints.path_to_waypoint` data are retrieved. If data are
     * unchanged since this timestamp, the fields above are
     * not set in the response. If `remaining_waypoints_route_version` is
     * unspecified, traffic and path are always retrieved.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp remaining_waypoints_route_version = 10;</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setRemainingWaypointsRouteVersion($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->remaining_waypoints_route_version = $var;

        return $this;
    }

}

