pub enum Flag {
Short(ShortFlag),
Long(LongFlag),
}Expand description
A primitive flag token.
Variants§
Implementations§
Source§impl Flag
impl Flag
Sourcepub fn try_from_token(token: &str) -> Result<Self, FlagNameError>
pub fn try_from_token(token: &str) -> Result<Self, FlagNameError>
Parses a primitive flag token.
§Errors
Returns FlagNameError when the token is not a supported short or long flag token.
Trait Implementations§
impl Eq for Flag
impl StructuralPartialEq for Flag
Auto Trait Implementations§
impl Freeze for Flag
impl RefUnwindSafe for Flag
impl Send for Flag
impl Sync for Flag
impl Unpin for Flag
impl UnsafeUnpin for Flag
impl UnwindSafe for Flag
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