Trait winnow::stream::FindSlice

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

Look for a slice in self

Required Methods§

source

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

Returns the offset of the slice if it is found

Implementations on Foreign Types§

source§

impl<'i> FindSlice<(char, char)> for &'i str

source§

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

source§

impl<'i> FindSlice<(char, char)> for &'i [u8]

source§

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

source§

impl<'i> FindSlice<(char, char, char)> for &'i str

source§

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

source§

impl<'i> FindSlice<(char, char, char)> for &'i [u8]

source§

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

source§

impl<'i> FindSlice<(char,)> for &'i str

source§

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

source§

impl<'i> FindSlice<(char,)> for &'i [u8]

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

source§

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

Implementors§

source§

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

source§

impl<'i, S> FindSlice<S> for &'i Bytes
where &'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>,