pub enum DrinkingStatusPreference {
OpenToAll,
No,
Yes,
Sometimes,
}Variants§
Implementations§
Source§impl DrinkingStatusPreference
impl DrinkingStatusPreference
Sourcepub fn to_value(&self) -> Option<DrinkingStatusValue>
pub fn to_value(&self) -> Option<DrinkingStatusValue>
Returns the base value for this preference option, if one exists.
Sourcepub fn from_value(value: DrinkingStatusValue) -> Self
pub fn from_value(value: DrinkingStatusValue) -> Self
Construct a preference value from a shared base value.
Sourcepub fn into_profile(self) -> Option<DrinkingStatusProfile>
pub fn into_profile(self) -> Option<DrinkingStatusProfile>
Convert this preference value into a profile variant when possible.
Trait Implementations§
Source§impl ApiEnum for DrinkingStatusPreference
impl ApiEnum for DrinkingStatusPreference
fn to_api_value(&self) -> i8
fn from_string(s: &str) -> Option<Self>
Source§impl Clone for DrinkingStatusPreference
impl Clone for DrinkingStatusPreference
Source§fn clone(&self) -> DrinkingStatusPreference
fn clone(&self) -> DrinkingStatusPreference
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DrinkingStatusPreference
impl Debug for DrinkingStatusPreference
Source§impl<'de> Deserialize<'de> for DrinkingStatusPreference
impl<'de> Deserialize<'de> for DrinkingStatusPreference
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<DrinkingStatusValue> for DrinkingStatusPreference
impl From<DrinkingStatusValue> for DrinkingStatusPreference
Source§fn from(value: DrinkingStatusValue) -> Self
fn from(value: DrinkingStatusValue) -> Self
Converts to this type from the input type.
Source§impl JsonSchema for DrinkingStatusPreference
impl JsonSchema for DrinkingStatusPreference
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &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 PartialEq for DrinkingStatusPreference
impl PartialEq for DrinkingStatusPreference
Source§impl Serialize for DrinkingStatusPreference
impl Serialize for DrinkingStatusPreference
impl StructuralPartialEq for DrinkingStatusPreference
Auto Trait Implementations§
impl Freeze for DrinkingStatusPreference
impl RefUnwindSafe for DrinkingStatusPreference
impl Send for DrinkingStatusPreference
impl Sync for DrinkingStatusPreference
impl Unpin for DrinkingStatusPreference
impl UnsafeUnpin for DrinkingStatusPreference
impl UnwindSafe for DrinkingStatusPreference
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