Enum google_api_proto::google::maps::routing::v2::RouteMatrixElementCondition
source · #[repr(i32)]pub enum RouteMatrixElementCondition {
Unspecified = 0,
RouteExists = 1,
RouteNotFound = 2,
}
Expand description
The condition of the route being returned.
Variants§
Unspecified = 0
Only used when the status
of the element is not OK.
RouteExists = 1
A route was found, and the corresponding information was filled out for the element.
RouteNotFound = 2
No route could be found. Fields containing route information, such as
distance_meters
or duration
, will not be filled out in the element.
Implementations§
source§impl RouteMatrixElementCondition
impl RouteMatrixElementCondition
sourcepub fn is_valid(value: i32) -> bool
pub fn is_valid(value: i32) -> bool
Returns true
if value
is a variant of RouteMatrixElementCondition
.
sourcepub fn from_i32(value: i32) -> Option<RouteMatrixElementCondition>
👎Deprecated: Use the TryFrom<i32> implementation instead
pub fn from_i32(value: i32) -> Option<RouteMatrixElementCondition>
Converts an i32
to a RouteMatrixElementCondition
, or None
if value
is not a valid variant.
source§impl RouteMatrixElementCondition
impl RouteMatrixElementCondition
sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
source§impl Clone for RouteMatrixElementCondition
impl Clone for RouteMatrixElementCondition
source§fn clone(&self) -> RouteMatrixElementCondition
fn clone(&self) -> RouteMatrixElementCondition
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for RouteMatrixElementCondition
impl Debug for RouteMatrixElementCondition
source§impl Default for RouteMatrixElementCondition
impl Default for RouteMatrixElementCondition
source§fn default() -> RouteMatrixElementCondition
fn default() -> RouteMatrixElementCondition
source§impl From<RouteMatrixElementCondition> for i32
impl From<RouteMatrixElementCondition> for i32
source§fn from(value: RouteMatrixElementCondition) -> i32
fn from(value: RouteMatrixElementCondition) -> i32
source§impl Hash for RouteMatrixElementCondition
impl Hash for RouteMatrixElementCondition
source§impl Ord for RouteMatrixElementCondition
impl Ord for RouteMatrixElementCondition
source§fn cmp(&self, other: &RouteMatrixElementCondition) -> Ordering
fn cmp(&self, other: &RouteMatrixElementCondition) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl PartialEq for RouteMatrixElementCondition
impl PartialEq for RouteMatrixElementCondition
source§fn eq(&self, other: &RouteMatrixElementCondition) -> bool
fn eq(&self, other: &RouteMatrixElementCondition) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for RouteMatrixElementCondition
impl PartialOrd for RouteMatrixElementCondition
source§fn partial_cmp(&self, other: &RouteMatrixElementCondition) -> Option<Ordering>
fn partial_cmp(&self, other: &RouteMatrixElementCondition) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl TryFrom<i32> for RouteMatrixElementCondition
impl TryFrom<i32> for RouteMatrixElementCondition
§type Error = UnknownEnumValue
type Error = UnknownEnumValue
source§fn try_from(value: i32) -> Result<RouteMatrixElementCondition, UnknownEnumValue>
fn try_from(value: i32) -> Result<RouteMatrixElementCondition, UnknownEnumValue>
impl Copy for RouteMatrixElementCondition
impl Eq for RouteMatrixElementCondition
impl StructuralPartialEq for RouteMatrixElementCondition
Auto Trait Implementations§
impl Freeze for RouteMatrixElementCondition
impl RefUnwindSafe for RouteMatrixElementCondition
impl Send for RouteMatrixElementCondition
impl Sync for RouteMatrixElementCondition
impl Unpin for RouteMatrixElementCondition
impl UnwindSafe for RouteMatrixElementCondition
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<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§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