Module bdrck::flags

source ·
Expand description

flags defines a library for command-line argument parsing.

Re-exports

pub use self::command::Command;
pub use self::command::CommandCallback;
pub use self::command::CommandResult;
pub use self::main_impl::main_impl_multiple_commands;
pub use self::main_impl::main_impl_single_command;
pub use self::spec::Spec;
pub use self::spec::Specs;
pub use self::value::Values;

Modules

command defines structures for configuring a command-line binary’s command(s). A binary might have several (sub-)Commands (e.g. like Git, where commit, log, etc. are all commands), or it might just have a single Command if it’s entirely a single-use binary.
main_impl provides command-line-application-specific main() implementations.
parse_and_execute provides functions to parse command-line arguments, and execute the relevant command based upon those arguments.
spec defines the structures which are used to describe a single command-line flag (Spec) or a set of flags as they relate to a command (Specs).
value defines structures which represent the values obtained by parsing command-line flags, and utilities for accessing them in a type-safe way.