pub enum StringOrBool {
String(String),
Bool(bool),
}
Variants§
Implementations§
source§impl StringOrBool
impl StringOrBool
fn is_string_or_true(&self) -> bool
Trait Implementations§
source§impl Clone for StringOrBool
impl Clone for StringOrBool
source§fn clone(&self) -> StringOrBool
fn clone(&self) -> StringOrBool
Returns a copy 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 StringOrBool
impl Debug for StringOrBool
source§impl Default for StringOrBool
impl Default for StringOrBool
source§fn default() -> StringOrBool
fn default() -> StringOrBool
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for StringOrBool
impl<'de> Deserialize<'de> for StringOrBool
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 PartialEq for StringOrBool
impl PartialEq for StringOrBool
source§fn eq(&self, other: &StringOrBool) -> bool
fn eq(&self, other: &StringOrBool) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for StringOrBool
impl StructuralPartialEq for StringOrBool
Auto Trait Implementations§
impl Freeze for StringOrBool
impl RefUnwindSafe for StringOrBool
impl Send for StringOrBool
impl Sync for StringOrBool
impl Unpin for StringOrBool
impl UnwindSafe for StringOrBool
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 24 bytes
Size for each variant:
String
: 24 bytesBool
: 9 bytes