Trait input_linux::enum_iterator::IterableEnum

source ·
pub trait IterableEnum: Sized {
    // Required methods
    fn iter_next(v: usize) -> Option<(usize, Self)>;
    fn iter() -> EnumIterator<Self> ;
}
Expand description

Allows EnumIterator to iterate over an enum type.

Required Methods§

source

fn iter_next(v: usize) -> Option<(usize, Self)>

Given an index into the iterator, return the value and the next index.

Iterators shall start by calling this with 0.

source

fn iter() -> EnumIterator<Self>

Instantiates an EnumIterator for an iterable type.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl IterableEnum for u16

Implementors§