pub enum FlagType {
Bool,
String,
Int,
Float,
}
Expand description
Enum shows FlagType
Variants
Bool
Variant shows bool
String
Variant shows string
Int
Variant shows int
Float
Variant shows float
Implementations
sourceimpl FlagType
impl FlagType
sourcepub fn default_flag_value(&self) -> FlagValue
pub fn default_flag_value(&self) -> FlagValue
Get this FlagType variant’s default value
sourcepub fn is_type_of(&self, val: &FlagValue) -> bool
pub fn is_type_of(&self, val: &FlagValue) -> bool
If val’s type is &self, returns true valが&selfが示すタイプと一致するか判定する
sourcepub fn get_value_from_string(&self, val: String) -> FlagValue
pub fn get_value_from_string(&self, val: String) -> FlagValue
Get FlagValue from val as &self type. valを&self型とした場合のFlagValueを取得する
sourcepub fn get_value_if_no_value(&self) -> FlagValue
pub fn get_value_if_no_value(&self) -> FlagValue
Returns &self type value in case of no specified value. フラグとして指定された値がなかった場合、&self型のフラグはどの値として扱うかを取得する
Trait Implementations
sourceimpl PartialOrd<FlagType> for FlagType
impl PartialOrd<FlagType> for FlagType
sourcefn partial_cmp(&self, other: &FlagType) -> Option<Ordering>
fn partial_cmp(&self, other: &FlagType) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl StructuralPartialEq for FlagType
Auto Trait Implementations
impl RefUnwindSafe for FlagType
impl Send for FlagType
impl Sync for FlagType
impl Unpin for FlagType
impl UnwindSafe for FlagType
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more