Struct cargo_metadata::Metadata [−][src]
Starting point for metadata returned by cargo metadata
Fields
packages: Vec<Package>
A list of all crates referenced by this crate (and the crate itself)
workspace_members: Vec<PackageId>
A list of all workspace members
resolve: Option<Resolve>
Dependencies graph
workspace_root: PathBuf
Workspace root
target_directory: PathBuf
Build directory
workspace_metadata: Value
The workspace-level metadata object. Null if non-existent.
Implementations
impl Metadata
[src]
pub fn root_package(&self) -> Option<&Package>
[src]
Get the root package of this metadata instance.
Trait Implementations
impl Clone for Metadata
[src]
impl Debug for Metadata
[src]
impl<'de> Deserialize<'de> for Metadata
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl<'a> Index<&'a PackageId> for Metadata
[src]
type Output = Package
The returned type after indexing.
fn index(&self, idx: &'a PackageId) -> &Package
[src]
impl Serialize for Metadata
[src]
Auto Trait Implementations
impl RefUnwindSafe for Metadata
impl Send for Metadata
impl Sync for Metadata
impl Unpin for Metadata
impl UnwindSafe for Metadata
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,