[][src]Trait num_enum::TryFromPrimitive

pub trait TryFromPrimitive: Sized {
    type Primitive: Copy + Eq + Debug;

    const NAME: &'static str;

    fn try_from_primitive(
        number: Self::Primitive
    ) -> Result<Self, TryFromPrimitiveError<Self>>; }

Associated Types

Loading content...

Associated Constants

const NAME: &'static str

Loading content...

Required methods

fn try_from_primitive(
    number: Self::Primitive
) -> Result<Self, TryFromPrimitiveError<Self>>

Loading content...

Implementors

Loading content...