//! Data container implementations for [`Vec<U>`].
usecrate::traits::IndexedDataContainer;/// Trait methods for the commonly-used `Vec<U>` data container.
////// Note that the associated `Item` type is always a *reference* to the data elements.
impl<U> IndexedDataContainer forVec<U>where
U: Clone,
{typeItem<'a>=&'a U whereSelf:'a;typeOwnedItem= U;// type Output = Vec<U>;
fnget_value(&self, index:usize)->Self::Item<'_>{self.get(index).unwrap()}fnget_owned(&self, index:usize)-><Selfas IndexedDataContainer>::OwnedItem{self.get(index).unwrap().to_owned()}fnlen(&self)->usize{self.len()}fnis_valid_index(&self, index:usize)->bool{self.get(index).is_some()}// fn new_from_indices(&self, indices: &[usize]) -> Self::Output {
// Vec::from_iter(indices.iter().map(|&idx| (*self.get_value(idx)).clone()))
//}
}