Trait winnow::stream::FindSlice

source ·
pub trait FindSlice<T> {
    // Required method
    fn find_slice(&self, substr: T) -> Option<usize>;
}
Expand description

Look for a slice in self

Required Methods§

source

fn find_slice(&self, substr: T) -> Option<usize>

Returns the offset of the slice if it is found

Implementations on Foreign Types§

source§

impl<'i, 's> FindSlice<&'s [u8]> for &'i [u8]

source§

fn find_slice(&self, substr: &'s [u8]) -> Option<usize>

source§

impl<'i> FindSlice<u8> for &'i [u8]

source§

fn find_slice(&self, substr: u8) -> Option<usize>

source§

impl<'i, 's> FindSlice<&'s str> for &'i [u8]

source§

fn find_slice(&self, substr: &'s str) -> Option<usize>

source§

impl<'i> FindSlice<char> for &'i str

source§

fn find_slice(&self, substr: char) -> Option<usize>

source§

impl<'i, 's> FindSlice<&'s str> for &'i str

source§

fn find_slice(&self, substr: &'s str) -> Option<usize>

Implementors§

source§

impl<'i, S> FindSlice<S> for &'i BStrwhere &'i [u8]: FindSlice<S>,

source§

impl<'i, S> FindSlice<S> for &'i Byteswhere &'i [u8]: FindSlice<S>,

source§

impl<I, S, T> FindSlice<T> for Stateful<I, S>where I: FindSlice<T>,

source§

impl<I, T> FindSlice<T> for Located<I>where I: FindSlice<T>,

source§

impl<I, T> FindSlice<T> for Partial<I>where I: FindSlice<T>,