[][src]Struct clip::Arg

pub struct Arg<'a> { /* fields omitted */ }

Methods

impl<'a> Arg<'a>[src]

pub fn new(name: &'a str) -> Self[src]

pub fn has_name(&self, name: &'a str) -> bool[src]

Is this string this argument's name?

pub fn is_flag(&self) -> bool[src]

Is this argument a flag or a name?

pub fn num_values(self, n: i32) -> Self[src]

Set the number of values this argument accepts IF its a flag!

pub fn get_values(&self) -> Values<'a>[src]

pub fn is_match(&self, slice_matches: &[&'a str]) -> bool[src]

Test if this Arg could consume a list of values If this arg has already consumed arguments, it wont match A name must accept exactly one argument

pub fn consume<'b>(&mut self, values: &'b mut Values<'a>) -> bool[src]

Takes an array of values and consumes data from them Returns true if did consume, returns false if did not consume

Trait Implementations

impl<'a> Debug for Arg<'a>[src]

impl<'a> PartialEq<Arg<'a>> for Arg<'a>[src]

impl<'a> Eq for Arg<'a>[src]

impl<'a> Copy for Arg<'a>[src]

impl<'a> Clone for Arg<'a>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl<'a> Unpin for Arg<'a>

impl<'a> Send for Arg<'a>

impl<'a> Sync for Arg<'a>

Blanket Implementations

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]