#[non_exhaustive]
pub struct Config<'c> { pub seed: FeatureSet<'c>, pub include: FeatureSet<'c>, pub deny: FeatureSet<'c>, pub skip: FeatureMatrix<'c>, pub include_hidden: bool, pub conflict: HashSet<FeatureSet<'c>>, }

Fields (Non-exhaustive)

This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
seed: FeatureSet<'c>

If this set is not empty, only these features will be used to construct the matrix.

include: FeatureSet<'c>

All of these features will be included in every feature set in the matrix.

deny: FeatureSet<'c>

Any feature set that includes any of these will be excluded from the matrix. This includes features enabled by other features.

This can be used for things like having an “__unstable” feature that gets enabled by any other features that use unstable rust features and then excluding “__unstable” if not on nightly.

skip: FeatureMatrix<'c>

These sets will be dropped from the matrix.

include_hidden: bool

Some crates prepend internal features with a double underscore. If this flag is not set, those features will not be used to build the matrix, but will be allowed if they are enabled by other features.

conflict: HashSet<FeatureSet<'c>>

List sets of features that can’t be used together. Any generated feature set that is a superset of any of these sets will be dropped from the matrix.

Implementations

Trait Implementations

Returns the “default value” for a type. Read more

Deserialize this value from the given Serde deserializer. Read more

Returns the Metadata for this provider, identifying itself and its configuration sources. Read more

Returns the configuration data.

Optionally returns a profile to set on the Figment this provider is merged into. The profile is only set if self is merged. Read more

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.