[−][src]Struct climake::CLIMake
Main structure for climake, the CLIMake object. Further arguments can easily be added using CLIMake::add_existing_arg.
Fields
name: String
Name of overall CLI
description: Option<String>
Description of CLI (if any)
args: Vec<Argument>
Arguments included
none_run: Option<Box<dyn Fn()>>
An optional run parameter if no arguments are passed. If this is Option::None and no arguments are passed, climake will default to CLIMakeError::NoArgumentsPassed.
Methods
impl CLIMake
[src]
pub fn parse_args(&mut self)
[src]
Parses arguments given from the avalible CLIMake::args and runs the corrosponding tasks in order.
NOTE: This function will eventually close the program running using std::process.
pub fn add_existing_arg(
&mut self,
new_arg: Argument
) -> Result<(), CLIMakeError>
[src]
&mut self,
new_arg: Argument
) -> Result<(), CLIMakeError>
Adds a new argument to parser.
pub fn help_msg(&self) -> String
[src]
Displays help message in stdout
using added arguments.
Auto Trait Implementations
impl !RefUnwindSafe for CLIMake
impl !Send for CLIMake
impl !Sync for CLIMake
impl Unpin for CLIMake
impl !UnwindSafe for CLIMake
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,