pub struct OutputM<M, EM, S>{ /* private fields */ }
Expand description
Trait Implementations§
Source§impl<M, EM, S> OutputMode for OutputM<M, EM, S>
impl<M, EM, S> OutputMode for OutputM<M, EM, S>
Source§type Error = EM
type Error = EM
Defines the Mode for the output type. Emit will generate the value, Check will
apply the parser but will only generate
()
if an error happened. Emit should be
used when we want to handle the error and extract useful information from it. Check
is used when we just want to know if parsing failed and reject the data quickly.Source§type Incomplete = S
type Incomplete = S
Indicates whether the input data is “complete”, ie we already have the entire data in the
buffer, or if it is “streaming”, where more data can be added later in the buffer. In
streaming mode, the parser will understand that a failure may mean that we are missing
data, and will return a specific error branch, Err::Incomplete to signal it. In complete
mode, the parser will generate a normal error
Auto Trait Implementations§
impl<M, EM, S> Freeze for OutputM<M, EM, S>
impl<M, EM, S> RefUnwindSafe for OutputM<M, EM, S>
impl<M, EM, S> Send for OutputM<M, EM, S>
impl<M, EM, S> Sync for OutputM<M, EM, S>
impl<M, EM, S> Unpin for OutputM<M, EM, S>
impl<M, EM, S> UnwindSafe for OutputM<M, EM, S>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more