Struct wasmer_pack::Metadata
source · #[non_exhaustive]pub struct Metadata {
pub package_name: PackageName,
pub version: String,
pub description: Option<String>,
}
Expand description
Information about the Package
being generated.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.package_name: PackageName
The package’s name.
version: String
A semver-compliant version number.
description: Option<String>
Extended information about the package.
Implementations§
source§impl Metadata
impl Metadata
sourcepub fn new(package_name: PackageName, version: impl Into<String>) -> Self
pub fn new(package_name: PackageName, version: impl Into<String>) -> Self
Create a new Metadata
object with all required fields.
sourcepub fn with_description(self, description: impl Into<String>) -> Self
pub fn with_description(self, description: impl Into<String>) -> Self
Set the Metadata::description
field.
Trait Implementations§
source§impl PartialEq<Metadata> for Metadata
impl PartialEq<Metadata> for Metadata
impl Eq for Metadata
impl StructuralEq for Metadata
impl StructuralPartialEq for Metadata
Auto Trait Implementations§
impl RefUnwindSafe for Metadata
impl Send for Metadata
impl Sync for Metadata
impl Unpin for Metadata
impl UnwindSafe for Metadata
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.