Skip to main content

KnownTag

Trait KnownTag 

Source
pub trait KnownTag {
    // Required methods
    fn key() -> KnownTags;
    fn value(&self) -> TagValue;
    fn from_value(value: &TagValue) -> Option<Self>
       where Self: Sized;

    // Provided methods
    fn from_tags(tags: &Tags) -> Option<Self>
       where Self: Sized { ... }
    fn tag(&self) -> Tag { ... }
}

Required Methods§

Source

fn key() -> KnownTags

Source

fn value(&self) -> TagValue

Source

fn from_value(value: &TagValue) -> Option<Self>
where Self: Sized,

Provided Methods§

Source

fn from_tags(tags: &Tags) -> Option<Self>
where Self: Sized,

Source

fn tag(&self) -> Tag

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§