pub struct LicenseRequirement {
pub license: String,
pub or_later: bool,
pub exception: Option<String>,
}Expand description
a single license requirement: one identifier plus the WITH exception
bound to it, if any.
Fields§
§license: Stringthe license identifier, e.g. GPL-2.0-only or LicenseRef-proprietary.
or_later: boolwhether the identifier carried a + suffix.
exception: Option<String>the exception identifier following WITH.
Implementations§
Trait Implementations§
Source§impl Clone for LicenseRequirement
impl Clone for LicenseRequirement
Source§fn clone(&self) -> LicenseRequirement
fn clone(&self) -> LicenseRequirement
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 LicenseRequirement
impl Debug for LicenseRequirement
Source§impl Display for LicenseRequirement
impl Display for LicenseRequirement
impl Eq for LicenseRequirement
Source§impl Hash for LicenseRequirement
impl Hash for LicenseRequirement
Source§impl Ord for LicenseRequirement
impl Ord for LicenseRequirement
Source§fn cmp(&self, other: &LicenseRequirement) -> Ordering
fn cmp(&self, other: &LicenseRequirement) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for LicenseRequirement
impl PartialEq for LicenseRequirement
Source§impl PartialOrd for LicenseRequirement
impl PartialOrd for LicenseRequirement
impl StructuralPartialEq for LicenseRequirement
Auto Trait Implementations§
impl Freeze for LicenseRequirement
impl RefUnwindSafe for LicenseRequirement
impl Send for LicenseRequirement
impl Sync for LicenseRequirement
impl Unpin for LicenseRequirement
impl UnsafeUnpin for LicenseRequirement
impl UnwindSafe for LicenseRequirement
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> Comparable<K> for Q
impl<Q, K> Comparable<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.