pub struct WorkspaceDepRequirements { /* private fields */ }Expand description
Raw requirement strings from the workspace root’s
[workspace.<kind>-dependencies] tables, keyed by kind then
dependency name. Carried for publish-time archive
normalization, which writes the author’s original spelling —
the parsed semver::VersionReq would respell it ("0.2"
renders as "^0.2").
Implementations§
Source§impl WorkspaceDepRequirements
impl WorkspaceDepRequirements
Sourcepub fn insert(
&mut self,
kind: DependencyKind,
name: String,
requirement: String,
)
pub fn insert( &mut self, kind: DependencyKind, name: String, requirement: String, )
Record the raw requirement string for (kind, name).
Sourcepub fn requirement(&self, kind: DependencyKind, name: &str) -> Option<&str>
pub fn requirement(&self, kind: DependencyKind, name: &str) -> Option<&str>
The raw requirement string for (kind, name). The lookup is
strictly kind-specific, mirroring the loader’s rule.
Trait Implementations§
Source§impl Clone for WorkspaceDepRequirements
impl Clone for WorkspaceDepRequirements
Source§fn clone(&self) -> WorkspaceDepRequirements
fn clone(&self) -> WorkspaceDepRequirements
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 WorkspaceDepRequirements
impl Debug for WorkspaceDepRequirements
Source§impl Default for WorkspaceDepRequirements
impl Default for WorkspaceDepRequirements
Source§fn default() -> WorkspaceDepRequirements
fn default() -> WorkspaceDepRequirements
Returns the “default value” for a type. Read more
impl Eq for WorkspaceDepRequirements
Source§impl PartialEq for WorkspaceDepRequirements
impl PartialEq for WorkspaceDepRequirements
Source§fn eq(&self, other: &WorkspaceDepRequirements) -> bool
fn eq(&self, other: &WorkspaceDepRequirements) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for WorkspaceDepRequirements
Auto Trait Implementations§
impl Freeze for WorkspaceDepRequirements
impl RefUnwindSafe for WorkspaceDepRequirements
impl Send for WorkspaceDepRequirements
impl Sync for WorkspaceDepRequirements
impl Unpin for WorkspaceDepRequirements
impl UnsafeUnpin for WorkspaceDepRequirements
impl UnwindSafe for WorkspaceDepRequirements
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.