Struct guppy::graph::EnabledStatus[][src]

pub struct EnabledStatus<'g> { /* fields omitted */ }
Expand description

Whether a dependency or feature is required, optional, or disabled.

Returned by the methods on DependencyMetadata.

Examples

[dependencies]
once_cell = "1"

The dependency and default features are required on all platforms.

[dependencies]
once_cell = { version = "1", optional = true }

The dependency and default features are optional on all platforms.

[target.'cfg(windows)'.dependencies]
once_cell = { version = "1", optional = true }

The result is platform-dependent. On Windows, the dependency and default features are both optional. On non-Windows platforms, the dependency and default features are disabled.

[dependencies]
once_cell = { version = "1", optional = true }

[target.'cfg(windows)'.dependencies]
once_cell = { version = "1", optional = false, default-features = false }

The result is platform-dependent. On Windows, the dependency is mandatory and default features are optional (i.e. enabled if the once_cell feature is turned on).

On Unix platforms, the dependency and default features are both optional.

Implementations

Returns true if this dependency is required on all platforms.

Returns true if this dependency is never enabled on any platform.

Evaluates whether this dependency is required on the given platform.

Returns Unknown if the result was unknown, which may happen if the platform’s target features are unknown.

Returns true if there are any platforms on which this dependency is required.

Evaluates whether this dependency is enabled (required or optional) on the given platform.

Returns Unknown if the result was unknown, which may happen if the platform’s target features are unknown.

Returns true if there are any platforms on which this dependency is enabled (required or optional).

Returns the PlatformStatus corresponding to whether this dependency is required.

Returns the PlatformStatus corresponding to whether this dependency is optional.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. 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

Clone this value, and then immediately put it into a Box behind a trait object of this trait. Read more

Returns the address of self. Read more

Performs the conversion.

Performs the conversion.

Clone this value, and then immediately put it into a Box behind a trait object of this trait. Read more

Returns the address of self. Read more

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Given ptr, which was obtained from a prior call to Self::borrow(), return a value with the same nominal lifetime which is guaranteed to survive mutations to Self. Read more

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

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.