pub struct ParsedFlag {
pub name: String,
pub value: Option<String>,
}Expand description
A parsed flag from a command’s argument list.
Fields§
§name: StringThe flag name without its value (e.g., --force, -f).
value: Option<String>Value if specified with = (e.g., --color=always → Some("always")).
Trait Implementations§
Source§impl Clone for ParsedFlag
impl Clone for ParsedFlag
Source§fn clone(&self) -> ParsedFlag
fn clone(&self) -> ParsedFlag
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 moreSource§impl Debug for ParsedFlag
impl Debug for ParsedFlag
Source§impl PartialEq for ParsedFlag
impl PartialEq for ParsedFlag
Source§fn eq(&self, other: &ParsedFlag) -> bool
fn eq(&self, other: &ParsedFlag) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ParsedFlag
impl StructuralPartialEq for ParsedFlag
Auto Trait Implementations§
impl Freeze for ParsedFlag
impl RefUnwindSafe for ParsedFlag
impl Send for ParsedFlag
impl Sync for ParsedFlag
impl Unpin for ParsedFlag
impl UnsafeUnpin for ParsedFlag
impl UnwindSafe for ParsedFlag
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