pub enum AccessMethod {
Open,
Token,
LicensePlate,
AccessCode,
Intercom,
ParkingTicket,
}Available on crate features
bookings and v2_3_0 only.Expand description
How a driver gets access to a reserved charger.
Spec: 2.3.0-bookings §mod_bookings_access_method_enum
Variants§
Open
Open access to the site.
Wire value: OPEN
Token
Using a token that was sent in the booking.
Wire value: TOKEN
LicensePlate
The licence plate of the vehicle that wants to charge.
Wire value: LICENSE_PLATE
AccessCode
The access code provided.
Wire value: ACCESS_CODE
Intercom
Ring the intercom.
Wire value: INTERCOM
ParkingTicket
A parking ticket is required.
Wire value: PARKING_TICKET
Implementations§
Source§impl AccessMethod
impl AccessMethod
Sourcepub const ALL_WIRE: &'static [&'static str]
pub const ALL_WIRE: &'static [&'static str]
Every wire value this enum accepts, in declaration order.
Sourcepub fn from_str_ignore_case(s: &str) -> Option<Self>
pub fn from_str_ignore_case(s: &str) -> Option<Self>
Parses a wire value, ignoring ASCII case.
OCPI enum values are case-sensitive, so this is only for peers known to get the
case wrong; FromStr is the strict version.
Trait Implementations§
Source§impl Clone for AccessMethod
impl Clone for AccessMethod
Source§fn clone(&self) -> AccessMethod
fn clone(&self) -> AccessMethod
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for AccessMethod
Source§impl Debug for AccessMethod
impl Debug for AccessMethod
Source§impl<'de> Deserialize<'de> for AccessMethod
impl<'de> Deserialize<'de> for AccessMethod
Source§fn deserialize<D: Deserializer<'de>>(d: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(d: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for AccessMethod
impl Display for AccessMethod
impl Eq for AccessMethod
Source§impl FromStr for AccessMethod
impl FromStr for AccessMethod
Source§impl Hash for AccessMethod
impl Hash for AccessMethod
Source§impl JsonSchema for AccessMethod
impl JsonSchema for AccessMethod
Source§fn json_schema(_g: &mut SchemaGenerator) -> Schema
fn json_schema(_g: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl Ord for AccessMethod
impl Ord for AccessMethod
Source§fn cmp(&self, other: &AccessMethod) -> Ordering
fn cmp(&self, other: &AccessMethod) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for AccessMethod
impl PartialEq for AccessMethod
Source§impl PartialOrd for AccessMethod
impl PartialOrd for AccessMethod
Source§impl Serialize for AccessMethod
impl Serialize for AccessMethod
impl StructuralPartialEq for AccessMethod
Source§impl Validate for AccessMethod
impl Validate for AccessMethod
Auto Trait Implementations§
impl Freeze for AccessMethod
impl RefUnwindSafe for AccessMethod
impl Send for AccessMethod
impl Sync for AccessMethod
impl Unpin for AccessMethod
impl UnsafeUnpin for AccessMethod
impl UnwindSafe for AccessMethod
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<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
Compare self to
key and return true if they are equal.