Struct sixtyfps_corelib::model::VecModel [−][src]
pub struct VecModel<T> { /* fields omitted */ }
Expand description
A model backed by a SharedVector
Implementations
Allocate a new model from a slice
Trait Implementations
type Data = T
type Data = T
The model data: A model is a set of row and each row has this data
Returns the data for a particular row. This function should be called with row < row_count()
.
Sets the data for a particular row. This function should be called with row < row_count()
.
If the model cannot support data changes, then it is ok to do nothing (default implementation).
If the model can update the data, it should also call row_changed on its internal ModelNotify
. Read more
Should forward to the internal ModelNotify::attach
fn iter<'a>(&'a self) -> ModelIterator<'a, Self::Data>ⓘNotable traits for ModelIterator<'a, T>
impl<'a, T> Iterator for ModelIterator<'a, T> type Item = T;
where
Self: Sized,
fn iter<'a>(&'a self) -> ModelIterator<'a, Self::Data>ⓘNotable traits for ModelIterator<'a, T>
impl<'a, T> Iterator for ModelIterator<'a, T> type Item = T;
where
Self: Sized,
Returns an iterator visiting all elements of the model.
Auto Trait Implementations
impl<T> !RefUnwindSafe for VecModel<T>
impl<T> !UnwindSafe for VecModel<T>