Enum nom::Needed [−][src]
pub enum Needed { Unknown, Size(usize), }
Contains information on needed data if a parser returned Incomplete
Variants
Unknown
needs more data, but we do not know how much
Size(usize)
contains the required data size
Methods
impl Needed
[src]
impl Needed
pub fn is_known(&self) -> bool
[src]
pub fn is_known(&self) -> bool
pub fn map<F: FnOnce(usize) -> usize>(self, f: F) -> Needed
[src]
pub fn map<F: FnOnce(usize) -> usize>(self, f: F) -> Needed
Maps a Needed
to Needed
by appling a function to a contained Size
value.
Trait Implementations
impl Debug for Needed
[src]
impl Debug for Needed
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl PartialEq for Needed
[src]
impl PartialEq for Needed
fn eq(&self, other: &Needed) -> bool
[src]
fn eq(&self, other: &Needed) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Needed) -> bool
[src]
fn ne(&self, other: &Needed) -> bool
This method tests for !=
.
impl Eq for Needed
[src]
impl Eq for Needed
impl Clone for Needed
[src]
impl Clone for Needed
fn clone(&self) -> Needed
[src]
fn clone(&self) -> Needed
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Copy for Needed
[src]
impl Copy for Needed