Trait StrRead

Source
pub trait StrRead {
    // Required method
    fn peek_str(&self) -> Option<&str>;

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

The base trait that both RealStrRead and StringRead need to implement.

Required Methods§

Source

fn peek_str(&self) -> Option<&str>

Get a reference to the next &str.

Returns None if it’s empty.

Provided Methods§

Source

fn is_empty(&self) -> bool

Check if there is nothing to pop.

Implementations on Foreign Types§

Source§

impl StrRead for str

Source§

fn peek_str(&self) -> Option<&str>

Source§

impl StrRead for String

Source§

fn peek_str(&self) -> Option<&str>

Source§

impl<R: StrRead + ?Sized> StrRead for Box<R>

Source§

fn peek_str(&self) -> Option<&str>

Implementors§