Trait combine::stream::Range

source ·
pub trait Range {
    // Required method
    fn len(&self) -> usize;

    // Provided method
    fn is_empty(&self) -> bool { ... }
}
Expand description

Trait representing a range of elements.

Required Methods§

source

fn len(&self) -> usize

Returns the remaining length of self. The returned length need not be the same as the number of items left in the stream.

Provided Methods§

source

fn is_empty(&self) -> bool

Returns true if the range does not contain any elements (Range::len() == 0)

Implementations on Foreign Types§

source§

impl<'a> Range for &'a str

source§

fn len(&self) -> usize

source§

impl<'a, I> Range for &'a mut I
where I: Range + ?Sized,

source§

fn len(&self) -> usize

source§

impl<'a, T> Range for &'a [T]

source§

fn len(&self) -> usize

Implementors§