pub enum Nargs {
Precisely(u8),
Any,
AtLeastOne,
}
Expand description
The cardinality of inputs to match for an argument/option.
Inspired by argparse: https://docs.python.org/3/library/argparse.html#nargs
Variants§
Precisely(u8)
N
: Precisely N
values.
Any
*
: May be any number of values, including 0
.
AtLeastOne
+
: At least one value must be specified.
Trait Implementations§
source§impl PartialEq for Nargs
impl PartialEq for Nargs
impl Copy for Nargs
impl Eq for Nargs
impl StructuralEq for Nargs
impl StructuralPartialEq for Nargs
Auto Trait Implementations§
impl RefUnwindSafe for Nargs
impl Send for Nargs
impl Sync for Nargs
impl Unpin for Nargs
impl UnwindSafe for Nargs
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