timely::container::flatcontainer

Trait ReserveItems

Source
pub trait ReserveItems<T>: Region {
    // Required method
    fn reserve_items<I>(&mut self, items: I)
       where I: Iterator<Item = T> + Clone;
}
Expand description

Reserve space in the receiving region.

Closely related to Push, but separate because target type is likely different.

Required Methods§

Source

fn reserve_items<I>(&mut self, items: I)
where I: Iterator<Item = T> + Clone,

Ensure that the region can absorb items without reallocation.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<T, D> ReserveItems<D> for Vec<T>
where T: Clone,

Source§

fn reserve_items<I>(&mut self, items: I)
where I: Iterator<Item = D> + Clone,

Implementors§

Source§

impl<'a, 'b, R> ReserveItems<&'a &'b str> for StringRegion<R>
where 'b: 'a, R: for<'c> Region<ReadItem<'c> = &'c [u8]> + for<'c> ReserveItems<&'c [u8]> + 'c,

Source§

impl<'a, A, A_C> ReserveItems<&'a (A,)> for TupleARegion<A_C>
where A_C: Region + ReserveItems<&'a A>,

Source§

impl<'a, A, A_C, B, B_C> ReserveItems<&'a (A, B)> for TupleABRegion<A_C, B_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C> ReserveItems<&'a (A, B, C)> for TupleABCRegion<A_C, B_C, C_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C> ReserveItems<&'a (A, B, C, D)> for TupleABCDRegion<A_C, B_C, C_C, D_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C> ReserveItems<&'a (A, B, C, D, E)> for TupleABCDERegion<A_C, B_C, C_C, D_C, E_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C> ReserveItems<&'a (A, B, C, D, E, F)> for TupleABCDEFRegion<A_C, B_C, C_C, D_C, E_C, F_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C> ReserveItems<&'a (A, B, C, D, E, F, G)> for TupleABCDEFGRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C> ReserveItems<&'a (A, B, C, D, E, F, G, H)> for TupleABCDEFGHRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I)> for TupleABCDEFGHIRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J)> for TupleABCDEFGHIJRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J, K)> for TupleABCDEFGHIJKRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J, K, L)> for TupleABCDEFGHIJKLRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J, K, L, M)> for TupleABCDEFGHIJKLMRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C, N, N_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J, K, L, M, N)> for TupleABCDEFGHIJKLMNRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C, N_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C, N, N_C, O, O_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O)> for TupleABCDEFGHIJKLMNORegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C, N_C, O_C>

Source§

impl<'a, A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C, N, N_C, O, O_C, P, P_C> ReserveItems<&'a (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P)> for TupleABCDEFGHIJKLMNOPRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C, N_C, O_C, P_C>

Source§

impl<'a, R, O> ReserveItems<ReadSlice<'a, R, O>> for SliceRegion<R, O>
where R: Region + ReserveItems<<R as Region>::ReadItem<'a>> + 'a, O: OffsetContainer<<R as Region>::Index>,

Source§

impl<'a, RO, RI> ReserveItems<Product<<RO as Region>::ReadItem<'a>, <RI as Region>::ReadItem<'a>>> for ProductRegion<RO, RI>
where RO: Region + ReserveItems<<RO as Region>::ReadItem<'a>> + 'a, RI: Region + ReserveItems<<RI as Region>::ReadItem<'a>> + 'a,

Source§

impl<'a, T> ReserveItems<&'a Vec<T>> for OwnedRegion<T>
where [T]: ToOwned,

Source§

impl<'a, T> ReserveItems<&'a T> for MirrorRegion<T>
where T: for<'b> Index + for<'b> IntoOwned<'b, Owned = T>,

Source§

impl<'a, T, R, O> ReserveItems<&'a [T]> for SliceRegion<R, O>

Source§

impl<'a, T, R, O> ReserveItems<&'a Vec<T>> for SliceRegion<R, O>
where R: for<'b> Region + for<'b> ReserveItems<&'b T>, O: OffsetContainer<<R as Region>::Index>,

Source§

impl<'a, T, R, O, const N: usize> ReserveItems<&'a [T; N]> for SliceRegion<R, O>

Source§

impl<'a, T, TC, E, EC> ReserveItems<&'a Result<T, E>> for ResultRegion<TC, EC>
where T: 'a, E: 'a, TC: Region + ReserveItems<&'a T>, EC: Region + ReserveItems<&'a E>,

Source§

impl<'a, T, TR> ReserveItems<&'a Option<T>> for OptionRegion<TR>
where T: 'a, TR: Region + ReserveItems<&'a T>,

Source§

impl<'b, R> ReserveItems<&'b str> for StringRegion<R>
where R: for<'a> Region<ReadItem<'a> = &'a [u8]> + for<'a> ReserveItems<&'a [u8]> + 'a,

Source§

impl<'b, R> ReserveItems<&'b String> for StringRegion<R>
where R: for<'a> Region<ReadItem<'a> = &'a [u8]> + for<'a> ReserveItems<&'a [u8]> + 'a,

Source§

impl<'b, T> ReserveItems<&'b [T]> for OwnedRegion<T>
where [T]: ToOwned,

Source§

impl<'b, T, const N: usize> ReserveItems<&'b [T; N]> for OwnedRegion<T>
where T: Clone,

Source§

impl<A, A_C> ReserveItems<(A,)> for TupleARegion<A_C>
where A_C: Region + ReserveItems<A>,

Source§

impl<A, A_C, B, B_C> ReserveItems<(A, B)> for TupleABRegion<A_C, B_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>,

Source§

impl<A, A_C, B, B_C, C, C_C> ReserveItems<(A, B, C)> for TupleABCRegion<A_C, B_C, C_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C> ReserveItems<(A, B, C, D)> for TupleABCDRegion<A_C, B_C, C_C, D_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C> ReserveItems<(A, B, C, D, E)> for TupleABCDERegion<A_C, B_C, C_C, D_C, E_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C> ReserveItems<(A, B, C, D, E, F)> for TupleABCDEFRegion<A_C, B_C, C_C, D_C, E_C, F_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C> ReserveItems<(A, B, C, D, E, F, G)> for TupleABCDEFGRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C> ReserveItems<(A, B, C, D, E, F, G, H)> for TupleABCDEFGHRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C> ReserveItems<(A, B, C, D, E, F, G, H, I)> for TupleABCDEFGHIRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J)> for TupleABCDEFGHIJRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J, K)> for TupleABCDEFGHIJKRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>, K_C: Region + ReserveItems<K>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J, K, L)> for TupleABCDEFGHIJKLRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>, K_C: Region + ReserveItems<K>, L_C: Region + ReserveItems<L>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J, K, L, M)> for TupleABCDEFGHIJKLMRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>, K_C: Region + ReserveItems<K>, L_C: Region + ReserveItems<L>, M_C: Region + ReserveItems<M>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C, N, N_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J, K, L, M, N)> for TupleABCDEFGHIJKLMNRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C, N_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>, K_C: Region + ReserveItems<K>, L_C: Region + ReserveItems<L>, M_C: Region + ReserveItems<M>, N_C: Region + ReserveItems<N>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C, N, N_C, O, O_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J, K, L, M, N, O)> for TupleABCDEFGHIJKLMNORegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C, N_C, O_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>, K_C: Region + ReserveItems<K>, L_C: Region + ReserveItems<L>, M_C: Region + ReserveItems<M>, N_C: Region + ReserveItems<N>, O_C: Region + ReserveItems<O>,

Source§

impl<A, A_C, B, B_C, C, C_C, D, D_C, E, E_C, F, F_C, G, G_C, H, H_C, I, I_C, J, J_C, K, K_C, L, L_C, M, M_C, N, N_C, O, O_C, P, P_C> ReserveItems<(A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P)> for TupleABCDEFGHIJKLMNOPRegion<A_C, B_C, C_C, D_C, E_C, F_C, G_C, H_C, I_C, J_C, K_C, L_C, M_C, N_C, O_C, P_C>
where A_C: Region + ReserveItems<A>, B_C: Region + ReserveItems<B>, C_C: Region + ReserveItems<C>, D_C: Region + ReserveItems<D>, E_C: Region + ReserveItems<E>, F_C: Region + ReserveItems<F>, G_C: Region + ReserveItems<G>, H_C: Region + ReserveItems<H>, I_C: Region + ReserveItems<I>, J_C: Region + ReserveItems<J>, K_C: Region + ReserveItems<K>, L_C: Region + ReserveItems<L>, M_C: Region + ReserveItems<M>, N_C: Region + ReserveItems<N>, O_C: Region + ReserveItems<O>, P_C: Region + ReserveItems<P>,

Source§

impl<R, O, T> ReserveItems<T> for ConsecutiveOffsetPairs<R, O>
where R: Region<Index = (usize, usize)> + ReserveItems<T>, O: OffsetContainer<usize>,

Source§

impl<T> ReserveItems<T> for MirrorRegion<T>
where T: for<'a> Index + for<'a> IntoOwned<'a, Owned = T>,

Source§

impl<T, J> ReserveItems<CopyIter<J>> for OwnedRegion<T>
where J: IntoIterator<Item = T>, [T]: ToOwned,

Source§

impl<T, TC, E, EC> ReserveItems<Result<T, E>> for ResultRegion<TC, EC>
where TC: Region + ReserveItems<T>, EC: Region + ReserveItems<E>,

Source§

impl<T, TR> ReserveItems<Option<T>> for OptionRegion<TR>
where TR: Region + ReserveItems<T>,