Struct googapis::maps::fleetengine::v1::SearchVehiclesRequest [−][src]
pub struct SearchVehiclesRequest {Show 16 fields
pub header: Option<RequestHeader>,
pub parent: String,
pub pickup_point: Option<TerminalLocation>,
pub dropoff_point: Option<TerminalLocation>,
pub pickup_radius_meters: i32,
pub count: i32,
pub minimum_capacity: i32,
pub trip_types: Vec<i32>,
pub maximum_staleness: Option<Duration>,
pub vehicle_types: Vec<VehicleType>,
pub required_attributes: Vec<VehicleAttribute>,
pub required_one_of_attributes: Vec<VehicleAttributeList>,
pub required_one_of_attribute_sets: Vec<VehicleAttributeList>,
pub order_by: i32,
pub include_back_to_back: bool,
pub trip_id: String,
}
Expand description
SearchVehicles request message.
Fields
header: Option<RequestHeader>
The standard Fleet Engine request header.
parent: String
Required. Must be in the format “providers/{provider}”. 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.
pickup_point: Option<TerminalLocation>
Required. The pickup point to search near.
dropoff_point: Option<TerminalLocation>
The customer’s intended dropoff location. The field is required if trip_types contains TripType.SHARED.
pickup_radius_meters: i32
Required. Defines the vehicle search radius around the pickup point. Only vehicles within the search radius will be returned. Value must be between 400 and 10000 meters.
count: i32
Required. Specifies the maximum number of available vehicles to return. By default, the Fleet Engine limits the number to 50.
minimum_capacity: i32
Required. Specifies the minimum number of passengers allowed in the vehicle. Must number must be greater than or equal to one. The driver is not considered in the capacity search. This number indicates the number of passengers being considered for a trip.
trip_types: Vec<i32>
Required. Restricts the search to only those vehicles that support at least one of the specified trip types.
maximum_staleness: Option<Duration>
Restricts the search to only those vehicles that have updated their locations within the specified duration back from now. If this field is not set, the server uses five minutes as the default value.
vehicle_types: Vec<VehicleType>
Required. Restricts the search to those vehicles with the specified types. At least one vehicle type must be specified.
required_attributes: Vec<VehicleAttribute>
Callers can form complex logical operations using the requiredAttributes and requiredOneOfAttributes fields.
requiredAttributes is a list; requiredOneOfAttributes uses a message which allows a list of lists. In combination, the two fields allow the composition of this expression:
(required_attribute\[0\] AND required_attribute\[1\] AND ...)
AND
(required_one_of_attribute\[0][0\] OR required_one_of_attribute\[0][1\] OR ...)
AND
(required_one_of_attribute\[1][0\] OR required_one_of_attribute\[1][1\] OR ...)
Restricts the search to only those vehicles with the specified attributes. This field is a conjunction/AND operation. Your app can specify up to 100 attributes; however, the combined key:value string length cannot exceed 1024 characters.
required_one_of_attributes: Vec<VehicleAttributeList>
Restricts the search to only those vehicles with at least one of the specified attributes applied to each VehicleAttributeList. Within each list, a vehicle must match at least one of the attributes. This field is an inclusive disjunction/OR operation in each VehicleAttributeList and a conjunction/AND operation across the collection of VehicleAttributeList.
required_one_of_attribute_sets: Vec<VehicleAttributeList>
Restricts the search to only those vehicles with at least one set of the specified attributes in the VehicleAttributeList. Within each list, a vehicle must match all of the attributes. This field is a conjunction/AND operation in each VehicleAttributeList and inclusive disjunction/OR operation across the collection of VehicleAttributeList.
order_by: i32
Required. Specifies ordering criterion for results.
include_back_to_back: bool
Indicates if a vehicle with an active trip is eligible for
another match. If false
, a vehicle is excluded from search results.
If true
, search results include vehicles with TripStatus
of
ENROUTE_TO_DROPOFF
. The services only use this field if
the SearchVehicles
request has TripType
set to EXCLUSIVE.
Default value is false
.
trip_id: String
Indicates the ID of the trip the searchVehicleRequest is associated with.
Implementations
Returns an iterator which yields the valid enum values contained in trip_types
.
Appends the provided enum value to trip_types
.
Returns the enum value of order_by
, or the default if the field is set to an invalid enum value.
Sets order_by
to the provided enum value.
Trait Implementations
fn merge_field<B>(
&mut self,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext
) -> Result<(), DecodeError> where
B: Buf,
Returns the encoded length of the message without a length delimiter.
Encodes the message to a buffer. Read more
Encodes the message to a newly allocated buffer.
Encodes the message with a length-delimiter to a buffer. Read more
Encodes the message with a length-delimiter to a newly allocated buffer.
Decodes an instance of the message from a buffer. Read more
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
Decodes a length-delimited instance of the message from the buffer.
Decodes an instance of the message from a buffer, and merges it into self
. Read more
Decodes a length-delimited instance of the message from buffer, and
merges it into self
. Read more
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for SearchVehiclesRequest
impl Send for SearchVehiclesRequest
impl Sync for SearchVehiclesRequest
impl Unpin for SearchVehiclesRequest
impl UnwindSafe for SearchVehiclesRequest
Blanket Implementations
Mutably borrows from an owned value. Read more
Wrap the input message T
in a tonic::Request
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more