pub struct Dependency {
pub package_url: Option<String>,
pub metadata: Option<HashMap<String, MetadataValue>>,
pub relationship: Option<Relationship>,
pub scope: Option<Scope>,
pub dependencies: Option<Vec<String>>,
}
Fields§
§package_url: Option<String>
Package-url (PURL) of dependency. See https://github.com/package-url/purl-spec for more details.
metadata: Option<HashMap<String, MetadataValue>>
User-defined metadata to store domain-specific information limited to 8 keys with scalar values.
relationship: Option<Relationship>
A notation of whether a dependency is requested directly by this manifest or is a dependency of another dependency.
scope: Option<Scope>
A notation of whether the dependency is required for the primary build artifact (runtime) or is only used for development. Future versions of this specification may allow for more granular scopes.
dependencies: Option<Vec<String>>
Array of package-url (PURLs) of direct child dependencies.
Implementations§
Source§impl Dependency
impl Dependency
pub fn new() -> Dependency
Trait Implementations§
Source§impl Clone for Dependency
impl Clone for Dependency
Source§fn clone(&self) -> Dependency
fn clone(&self) -> Dependency
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for Dependency
impl Debug for Dependency
Source§impl Default for Dependency
impl Default for Dependency
Source§fn default() -> Dependency
fn default() -> Dependency
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for Dependency
impl<'de> Deserialize<'de> for Dependency
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for Dependency
impl PartialEq for Dependency
Source§impl Serialize for Dependency
impl Serialize for Dependency
impl StructuralPartialEq for Dependency
Auto Trait Implementations§
impl Freeze for Dependency
impl RefUnwindSafe for Dependency
impl Send for Dependency
impl Sync for Dependency
impl Unpin for Dependency
impl UnwindSafe for Dependency
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