[−][src]Trait subslice::SubsliceExt
Trait of types which can be searched for subsequences
Required methods
fn find(&self, other: &Self) -> Option<usize>
Find the first subslice of self
which is equal to other
, and return the index of its
start.
O(self.len() + other.len()
) time
fn rfind(&self, other: &Self) -> Option<usize>
Find the last subslice of self
which is equal to other
, and return the index of its
start.
O(self.len() + other.len()
) time
Implementors
impl SubsliceExt for str
[src]
impl SubsliceExt for str
fn find(&self, other: &Self) -> Option<usize> | [src] |
fn rfind(&self, other: &Self) -> Option<usize> | [src] |
impl<A: Ord> SubsliceExt for [A]
[src]
impl<A: Ord> SubsliceExt for [A]