Struct google_api_proto::maps::fleetengine::delivery::v1::VehicleJourneySegment
source · pub struct VehicleJourneySegment {
pub stop: Option<VehicleStop>,
pub driving_distance_meters: Option<i32>,
pub driving_duration: Option<Duration>,
pub path: Vec<LatLng>,
}
Expand description
Represents a Vehicle’s travel segment - from its previous stop to the current stop. If it is the first active stop, then it is from the Vehicle’s current location to this stop.
Fields§
§stop: Option<VehicleStop>
Specifies the stop location, along with the Task
s associated with
the stop. Some fields of the VehicleStop might not be present if this
journey segment is part of JourneySharingInfo
.
driving_distance_meters: Option<i32>
Output only. The travel distance from the previous stop to this stop.
If the current stop is the first stop in the list of journey
segments, then the starting point is the vehicle’s location recorded
at the time that this stop was added to the list. This field might not be
present if this journey segment is part of JourneySharingInfo
.
driving_duration: Option<Duration>
Output only. The travel time from the previous stop to this stop. If the current stop is the first stop in the list of journey segments, then the starting point is the Vehicle’s location recorded at the time that this stop was added to the list.
If this field is defined in the path
Task.remaining_vehicle_journey_segments\[0\].driving_duration
(gRPC) or
Task.remainingVehicleJourneySegments\[0\].drivingDuration
(REST),
then it may be populated with the value from
DeliveryVehicle.remaining_duration
(gRPC) or
DeliveryVehicle.remainingDuration
(REST).
This provides the remaining driving duration from the driver app’s latest
known location rather than the driving time from the previous stop.
path: Vec<LatLng>
Output only. The path from the previous stop to this stop. If the current
stop is the first stop in the list of journey segments, then this is the
path from the vehicle’s current location to this stop at the time that the
stop was added to the list. This field might not be present if this journey
segment is part of JourneySharingInfo
.
If this field is defined in the path
Task.journey_sharing_info.remaining_vehicle_journey_segments\[0\].path
(gRPC) or Task.journeySharingInfo.remainingVehicleJourneySegments\[0\].path
(REST), then it may be populated with the LatLng
s decoded from
DeliveryVehicle.current_route_segment
(gRPC) or
DeliveryVehicle.currentRouteSegment
(REST). This provides the driving
path from the driver app’s latest known location rather than the path from
the previous stop.
Trait Implementations§
source§impl Clone for VehicleJourneySegment
impl Clone for VehicleJourneySegment
source§fn clone(&self) -> VehicleJourneySegment
fn clone(&self) -> VehicleJourneySegment
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for VehicleJourneySegment
impl Debug for VehicleJourneySegment
source§impl Default for VehicleJourneySegment
impl Default for VehicleJourneySegment
source§impl Message for VehicleJourneySegment
impl Message for VehicleJourneySegment
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for VehicleJourneySegment
impl PartialEq for VehicleJourneySegment
source§fn eq(&self, other: &VehicleJourneySegment) -> bool
fn eq(&self, other: &VehicleJourneySegment) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for VehicleJourneySegment
Auto Trait Implementations§
impl Freeze for VehicleJourneySegment
impl RefUnwindSafe for VehicleJourneySegment
impl Send for VehicleJourneySegment
impl Sync for VehicleJourneySegment
impl Unpin for VehicleJourneySegment
impl UnwindSafe for VehicleJourneySegment
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request