pub trait PushPartitioned: SizableContainer {
// Required method
fn push_partitioned<I, F>(
&mut self,
buffers: &mut [Self],
index: I,
flush: F,
)
where I: for<'a> FnMut(&Self::Item<'a>) -> usize,
F: FnMut(usize, &mut Self);
}
Expand description
A container that can partition itself into pieces.
Required Methods§
Sourcefn push_partitioned<I, F>(&mut self, buffers: &mut [Self], index: I, flush: F)
fn push_partitioned<I, F>(&mut self, buffers: &mut [Self], index: I, flush: F)
Partition and push this container.
Drain all elements from self
, and use the function index
to determine which buffer
to
append an element to. Call flush
with an index and a buffer to send the data downstream.
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.