Struct cargo_modules::options::project::Options
source · pub struct Options {
pub lib: bool,
pub bin: Option<String>,
pub package: Option<String>,
pub no_default_features: bool,
pub all_features: bool,
pub features: Vec<String>,
pub target: Option<String>,
pub cfg_test: bool,
pub with_sysroot: bool,
pub manifest_path: PathBuf,
}Fields§
§lib: boolProcess only this package’s library.
bin: Option<String>Process only the specified binary.
package: Option<String>Package to process (see cargo help pkgid).
no_default_features: boolDo not activate the default feature.
all_features: boolActivate all available features.
features: Vec<String>List of features to activate.
This will be ignored if --cargo-all-features is provided.
target: Option<String>Analyze for target triple.
cfg_test: boolAnalyze with #[cfg(test)] enabled.
with_sysroot: boolInclude sysroot crates (std, core & friends) in analysis.
manifest_path: PathBufPath to Cargo.toml.
Trait Implementations§
source§impl PartialEq<Options> for Options
impl PartialEq<Options> for Options
source§impl StructOpt for Options
impl StructOpt for Options
source§fn from_clap(matches: &ArgMatches<'_>) -> Self
fn from_clap(matches: &ArgMatches<'_>) -> Self
Builds the struct from
clap::ArgMatches. It’s guaranteed to succeed
if matches originates from an App generated by StructOpt::clap called on
the same type, otherwise it must panic.source§fn from_args() -> Selfwhere
Self: Sized,
fn from_args() -> Selfwhere
Self: Sized,
Builds the struct from the command line arguments (
std::env::args_os).
Calls clap::Error::exit on failure, printing the error message and aborting the program.source§fn from_args_safe() -> Result<Self, Error>where
Self: Sized,
fn from_args_safe() -> Result<Self, Error>where
Self: Sized,
Builds the struct from the command line arguments (
std::env::args_os).
Unlike StructOpt::from_args, returns clap::Error on failure instead of aborting the program,
so calling .exit is up to you.source§fn from_iter<I>(iter: I) -> Selfwhere
Self: Sized,
I: IntoIterator,
<I as IntoIterator>::Item: Into<OsString> + Clone,
fn from_iter<I>(iter: I) -> Selfwhere
Self: Sized,
I: IntoIterator,
<I as IntoIterator>::Item: Into<OsString> + Clone,
Gets the struct from any iterator such as a
Vec of your making.
Print the error message and quit the program in case of failure. Read moresource§fn from_iter_safe<I>(iter: I) -> Result<Self, Error>where
Self: Sized,
I: IntoIterator,
<I as IntoIterator>::Item: Into<OsString> + Clone,
fn from_iter_safe<I>(iter: I) -> Result<Self, Error>where
Self: Sized,
I: IntoIterator,
<I as IntoIterator>::Item: Into<OsString> + Clone,
Gets the struct from any iterator such as a
Vec of your making. Read moreimpl Eq for Options
impl StructuralEq for Options
impl StructuralPartialEq for Options
Auto Trait Implementations§
impl RefUnwindSafe for Options
impl Send for Options
impl Sync for Options
impl Unpin for Options
impl UnwindSafe for Options
Blanket Implementations§
§impl<T> Cast for T
impl<T> Cast for T
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.