pub struct PackageData {Show 21 fields
pub version: Version,
pub name: String,
pub repository: Option<String>,
pub manifest: ManifestPath,
pub targets: Vec<Target>,
pub is_local: bool,
pub is_member: bool,
pub dependencies: Vec<PackageDependency>,
pub edition: Edition,
pub features: FxHashMap<String, Vec<String>>,
pub active_features: Vec<String>,
pub id: Arc<PackageId>,
pub authors: Vec<String>,
pub description: Option<String>,
pub homepage: Option<String>,
pub license: Option<String>,
pub license_file: Option<Utf8PathBuf>,
pub readme: Option<Utf8PathBuf>,
pub rust_version: Option<Version>,
pub metadata: RustAnalyzerPackageMetaData,
pub all_member_deps: Option<FxHashSet<Package>>,
}Expand description
Information associated with a cargo crate
Fields§
§version: VersionVersion given in the Cargo.toml
name: StringName as given in the Cargo.toml
repository: Option<String>Repository as given in the Cargo.toml
manifest: ManifestPathPath containing the Cargo.toml
targets: Vec<Target>Targets provided by the crate (lib, bin, example, test, …)
is_local: boolDoes this package come from the local filesystem (and is editable)?
is_member: boolWhether this package is a member of the workspace
dependencies: Vec<PackageDependency>List of packages this package depends on
edition: EditionRust edition for this package
features: FxHashMap<String, Vec<String>>Features provided by the crate, mapped to the features required by that feature.
active_features: Vec<String>List of features enabled on this package
id: Arc<PackageId>Package id
Authors as given in the Cargo.toml
description: Option<String>Description as given in the Cargo.toml
homepage: Option<String>Homepage as given in the Cargo.toml
license: Option<String>License as given in the Cargo.toml
license_file: Option<Utf8PathBuf>License file as given in the Cargo.toml
readme: Option<Utf8PathBuf>Readme file as given in the Cargo.toml
rust_version: Option<Version>Rust version as given in the Cargo.toml
metadata: RustAnalyzerPackageMetaDataThe contents of [package.metadata.rust-analyzer]
all_member_deps: Option<FxHashSet<Package>>If this package is a member of the workspace, store all direct and transitive dependencies as long as they are workspace members, to track dependency relationships between members.
Trait Implementations§
Source§impl Clone for PackageData
impl Clone for PackageData
Source§fn clone(&self) -> PackageData
fn clone(&self) -> PackageData
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PackageData
impl Debug for PackageData
Source§impl PartialEq for PackageData
impl PartialEq for PackageData
impl Eq for PackageData
impl StructuralPartialEq for PackageData
Auto Trait Implementations§
impl Freeze for PackageData
impl RefUnwindSafe for PackageData
impl Send for PackageData
impl Sync for PackageData
impl Unpin for PackageData
impl UnwindSafe for PackageData
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more