orx_concurrent_iter/implementations/vec_drain/
drainable.rs1use crate::{ConcurrentDrainableOverSlice, implementations::vec_drain::con_iter::ConIterVecDrain};
2use alloc::vec::Vec;
3use core::ops::RangeBounds;
4
5impl<T> ConcurrentDrainableOverSlice for Vec<T>
6where
7 T: Send,
8{
9 type Item = T;
10
11 type DrainingIter<'a>
12 = ConIterVecDrain<'a, T>
13 where
14 Self: 'a;
15
16 fn con_drain<R>(&mut self, range: R) -> Self::DrainingIter<'_>
17 where
18 R: RangeBounds<usize>,
19 {
20 ConIterVecDrain::new(self, range)
21 }
22}