Trait ComponentAccessor

Source
pub trait ComponentAccessor {
    // Required method
    fn component(&self, component: NonZeroUsize) -> Option<&Component>;
}
Expand description

A trait for accessing components on fields, to extend Option<&Repeat> with short-circuit access

Required Methods§

Source

fn component(&self, component: NonZeroUsize) -> Option<&Component>

Access the component given by 1-based indexing

Implementations on Foreign Types§

Source§

impl ComponentAccessor for Option<&Repeat>

Source§

fn component(&self, component: NonZeroUsize) -> Option<&Component>

Implementors§