[−][src]Function combine::stream::decode
pub fn decode<P>(
parser: P,
input: P::Input,
partial_state: &mut P::PartialState
) -> Result<(Option<P::Output>, usize), <P::Input as StreamOnce>::Error> where
P: Parser,
P::Input: RangeStream,
Decodes input
using parser
.
Return Ok(Some(item), consumed_data)
if there was enough data to finish parsing using
parser
.
Returns Ok(None, consumed_data)
if input
did not contain enough data to finish parsing
using parser
.
See examples/async.rs
for example usage in a tokio_io::codec::Decoder