Trait parsed::matcher::Matcher [−][src]
Required methods
fn do_match(&self, bs: &mut ByteStream) -> Result<T, MatchError>
[src]
Provided methods
fn boxed(self) -> Box<dyn Matcher<T>> where
Self: Sized + 'static,
[src]
Self: Sized + 'static,
fn then<U, That>(self, that: That) -> Chain<Self, That> where
Self: Sized,
That: Matcher<U>,
[src]
Self: Sized,
That: Matcher<U>,
fn then_with<U, F, N>(self, f: F) -> Expose<Self, F> where
Self: Sized,
F: Fn(&T) -> N + 'static,
N: Matcher<U>,
[src]
Self: Sized,
F: Fn(&T) -> N + 'static,
N: Matcher<U>,
fn map<U, F>(self, f: F) -> Map<Self, T, F> where
Self: Sized,
F: Fn(T) -> U + 'static,
[src]
Self: Sized,
F: Fn(T) -> U + 'static,
fn then_map<U, That, F, V>(
self,
that: That,
f: F
) -> Map<Chain<Self, That>, (T, U), F> where
Self: Sized,
That: Matcher<U>,
F: Fn((T, U)) -> V + 'static,
[src]
self,
that: That,
f: F
) -> Map<Chain<Self, That>, (T, U), F> where
Self: Sized,
That: Matcher<U>,
F: Fn((T, U)) -> V + 'static,
Implementations on Foreign Types
impl<T> Matcher<T> for Box<dyn Matcher<T>>
[src]
fn do_match(&self, bs: &mut ByteStream) -> Result<T, MatchError>
[src]
Implementors
impl<M, F, N, T, U> Matcher<(T, U)> for Expose<M, F> where
M: Matcher<T>,
F: Fn(&T) -> N + 'static,
N: Matcher<U>,
[src]
M: Matcher<T>,
F: Fn(&T) -> N + 'static,
N: Matcher<U>,
fn do_match(&self, bs: &mut ByteStream) -> Result<(T, U), MatchError>
[src]
impl<M, N, T, U> Matcher<(T, U)> for Chain<M, N> where
M: Matcher<T>,
N: Matcher<U>,
[src]
M: Matcher<T>,
N: Matcher<U>,
fn do_match(&self, bs: &mut ByteStream) -> Result<(T, U), MatchError>
[src]
impl<M, T, U> Matcher<T> for Skip<M, T, U> where
M: Matcher<(T, U)>,
[src]
M: Matcher<(T, U)>,
fn do_match(&self, bs: &mut ByteStream) -> Result<T, MatchError>
[src]
impl<M, T, U, F> Matcher<T> for Save<M, T, U, F> where
M: Matcher<(T, U)>,
F: Fn(&mut T, U),
[src]
M: Matcher<(T, U)>,
F: Fn(&mut T, U),
fn do_match(&self, bs: &mut ByteStream) -> Result<T, MatchError>
[src]
impl<M, T, U, F> Matcher<U> for Map<M, T, F> where
M: Matcher<T>,
F: Fn(T) -> U + 'static,
[src]
M: Matcher<T>,
F: Fn(T) -> U + 'static,
fn do_match(&self, bs: &mut ByteStream) -> Result<U, MatchError>
[src]
impl<T, F> Matcher<T> for F where
F: Fn(&mut ByteStream) -> Result<T, MatchError>,
[src]
F: Fn(&mut ByteStream) -> Result<T, MatchError>,