Struct crates_index::Version
source · pub struct Version { /* private fields */ }
Expand description
A single version of a crate (package) published to the index
Implementations§
source§impl Version
impl Version
sourcepub fn dependencies(&self) -> &[Dependency]
pub fn dependencies(&self) -> &[Dependency]
Dependencies for this version
sourcepub fn checksum(&self) -> &[u8; 32]
pub fn checksum(&self) -> &[u8; 32]
Checksum of the package for this version
SHA256 of the .crate file
sourcepub fn features(&self) -> &HashMap<String, Vec<String>>
pub fn features(&self) -> &HashMap<String, Vec<String>>
Explicit features this crate has. This list is not exhaustive, because any optional dependency becomes a feature automatically.
default
is a special feature name for implicitly enabled features.
sourcepub fn links(&self) -> Option<&str>
pub fn links(&self) -> Option<&str>
Exclusivity flag. If this is a sys crate, it informs it conflicts with any other crate with the same links string.
It does not involve linker or libraries in any way.
sourcepub fn download_url(&self, index: &IndexConfig) -> Option<String>
pub fn download_url(&self, index: &IndexConfig) -> Option<String>
Where to find crate tarball
Trait Implementations§
source§impl<'de> Deserialize<'de> for Version
impl<'de> Deserialize<'de> for Version
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