src/cli/getopts.rs: improve docs

This commit is contained in:
Dietmar Maurer 2019-02-21 09:36:52 +01:00
parent 4de0e142a0
commit 532a69eb04
2 changed files with 7 additions and 2 deletions

View File

@ -7,8 +7,9 @@
mod environment; mod environment;
pub use environment::*; pub use environment::*;
mod getopts;
pub use getopts::*;
mod command; mod command;
pub use command::*; pub use command::*;
mod getopts;
pub use getopts::*;

View File

@ -52,6 +52,10 @@ fn parse_argument(arg: &str) -> RawArgument {
}; };
} }
/// Parses command line arguments using a `Schema`
///
/// Returns parsed options as json object, together with the
/// list of additional command line arguments.
pub fn parse_arguments<T: AsRef<str>>( pub fn parse_arguments<T: AsRef<str>>(
args: &[T], args: &[T],
arg_param: &Vec<&'static str>, arg_param: &Vec<&'static str>,