Struct relm4::factory::collections::FactoryVecDeque
source · pub struct FactoryVecDeque<Data>where
Data: FactoryPrototype,{ /* private fields */ }
Implementations§
source§impl<Data> FactoryVecDeque<Data>where
Data: FactoryPrototype,
impl<Data> FactoryVecDeque<Data>where Data: FactoryPrototype,
sourcepub fn new() -> Self
pub fn new() -> Self
Create a new FactoryVecDeque
.
sourcepub fn from_vec_deque(data: VecDeque<Data>) -> Self
pub fn from_vec_deque(data: VecDeque<Data>) -> Self
Initialize a new FactoryVecDeque
with a normal VecDeque
.
sourcepub fn into_vec_deque(self) -> VecDeque<Data>
pub fn into_vec_deque(self) -> VecDeque<Data>
Get the internal data of the FactoryVecDeque
.
sourcepub fn clear(&mut self)
pub fn clear(&mut self)
Remove all data from the FactoryVecDeque
.
sourcepub fn push_back(&mut self, data: Data)
pub fn push_back(&mut self, data: Data)
Insert an element at the end of a FactoryVecDeque
.
sourcepub fn pop_back(&mut self) -> Option<Data>
pub fn pop_back(&mut self) -> Option<Data>
Remove an element at the end of a FactoryVecDeque
.
sourcepub fn push_front(&mut self, data: Data)
pub fn push_front(&mut self, data: Data)
Adds an element at the front.
source§impl<Data, View> FactoryVecDeque<Data>where
Data: FactoryPrototype<Factory = Self, View = View>,
View: FactoryView<Data::Root>,
impl<Data, View> FactoryVecDeque<Data>where Data: FactoryPrototype<Factory = Self, View = View>, View: FactoryView<Data::Root>,
Trait Implementations§
source§impl<Data> Debug for FactoryVecDeque<Data>where
Data: FactoryPrototype + Debug,
Data::Widgets: Debug,
Data::View: Debug,
Data::Root: Debug,
impl<Data> Debug for FactoryVecDeque<Data>where Data: FactoryPrototype + Debug, Data::Widgets: Debug, Data::View: Debug, Data::Root: Debug,
source§impl<Data> Default for FactoryVecDeque<Data>where
Data: FactoryPrototype + Default,
Data::Widgets: Default,
Data::View: Default,
Data::Root: Default,
impl<Data> Default for FactoryVecDeque<Data>where Data: FactoryPrototype + Default, Data::Widgets: Default, Data::View: Default, Data::Root: Default,
source§fn default() -> FactoryVecDeque<Data>
fn default() -> FactoryVecDeque<Data>
Returns the “default value” for a type. Read more
source§impl<Data, View> Factory<Data, View> for FactoryVecDeque<Data>where
Data: FactoryPrototype<Factory = Self, View = View>,
View: FactoryView<Data::Root> + FactoryListView<Data::Root>,
<Data as FactoryPrototype>::Root: Clone,
impl<Data, View> Factory<Data, View> for FactoryVecDeque<Data>where Data: FactoryPrototype<Factory = Self, View = View>, View: FactoryView<Data::Root> + FactoryListView<Data::Root>, <Data as FactoryPrototype>::Root: Clone,
§type Key = DynamicIndex
type Key = DynamicIndex
Key that provides additional information for the
FactoryPrototype
functions.