Trait TryFromAttributes

Source
pub trait TryFromAttributes
where Self: Sized,
{ // Required methods fn attr_name() -> &'static str; fn try_from_attributes(attrs: &[Attribute]) -> Result<Option<Self>>; // Provided method fn from_attributes(attrs: &[Attribute]) -> Result<Self> { ... } }

Required Methods§

Source

fn attr_name() -> &'static str

Source

fn try_from_attributes(attrs: &[Attribute]) -> Result<Option<Self>>

Provided Methods§

Source

fn from_attributes(attrs: &[Attribute]) -> Result<Self>

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§