trait ChunkBySlice<T>:
AsRef<[T]>
+ Default
+ Send {
// Required methods
fn split(self, index: usize) -> (Self, Self);
fn chunk_by(
self,
pred: &impl Fn(&T, &T) -> bool,
) -> impl Iterator<Item = Self>;
// Provided methods
fn find(
&self,
pred: &impl Fn(&T, &T) -> bool,
start: usize,
end: usize,
) -> Option<usize> { ... }
fn rfind(&self, pred: &impl Fn(&T, &T) -> bool, end: usize) -> Option<usize> { ... }
}
Required Methods§
fn split(self, index: usize) -> (Self, Self)
fn chunk_by(self, pred: &impl Fn(&T, &T) -> bool) -> impl Iterator<Item = Self>
Provided Methods§
fn find( &self, pred: &impl Fn(&T, &T) -> bool, start: usize, end: usize, ) -> Option<usize>
fn rfind(&self, pred: &impl Fn(&T, &T) -> bool, end: usize) -> Option<usize>
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.