#[non_exhaustive]pub enum ResolvedSource {
Registry {
url: String,
checksum: String,
},
Git {
url: String,
rev: String,
},
Path {
path: String,
},
}Expand description
Source of a resolved dependency.
Indicates where the package was downloaded from or how it was resolved.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Registry
From a registry with optional checksum
Git
From git with commit hash
Path
From local file system
Trait Implementations§
Source§impl Clone for ResolvedSource
impl Clone for ResolvedSource
Source§impl Debug for ResolvedSource
impl Debug for ResolvedSource
Source§fn fmt(&self, f: &mut Formatter<'_>) -> Result
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Manual, not derived: Registry/Git’s url is copied verbatim from the lock file
(e.g. Cargo’s git+https://user:token@host/repo, npm’s resolved) and can carry a
credential; Path’s path is also redacted defensively, since it is the catch-all a
caller may put an unrecognized URL scheme into (e.g. Cargo’s unknown-scheme+https://
sources — sparse+ itself is classified as Registry since #1320) rather than a
filesystem path (CWE-532, #1237).
impl Eq for ResolvedSource
Source§impl PartialEq for ResolvedSource
impl PartialEq for ResolvedSource
impl StructuralPartialEq for ResolvedSource
Auto Trait Implementations§
impl Freeze for ResolvedSource
impl RefUnwindSafe for ResolvedSource
impl Send for ResolvedSource
impl Sync for ResolvedSource
impl Unpin for ResolvedSource
impl UnsafeUnpin for ResolvedSource
impl UnwindSafe for ResolvedSource
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
Mutably borrows from an owned value. Read more
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§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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.