Trait smart_read::ReadLine

source ·
pub trait ReadLine {
    type Output;

    // Required method
    fn try_read_line(&self) -> BoxResult<Self::Output>;

    // Provided method
    fn read_line(&self) -> Self::Output { ... }
}
Expand description

This is what powers the whole crate. Anything that implements this can be passed to read!() and try_read!()

Required Associated Types§

Required Methods§

Provided Methods§

source

fn read_line(&self) -> Self::Output

Implementations on Foreign Types§

source§

impl<K, T> ReadLine for HashMap<K, T>
where T: ToString + Clone,

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T> ReadLine for &[T]
where T: ToString + Clone,

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T> ReadLine for LinkedList<T>
where T: ToString + Clone,

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T> ReadLine for VecDeque<T>
where T: ToString + Clone,

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T> ReadLine for Vec<T>
where T: ToString + Clone,

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T, const LEN: usize> ReadLine for &[T; LEN]
where T: ToString + Clone,

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T: Display + FromStr + PartialOrd<T>> ReadLine for Range<T>

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T: Display + FromStr + PartialOrd<T>> ReadLine for RangeFrom<T>

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T: Display + FromStr + PartialOrd<T>> ReadLine for RangeInclusive<T>

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T: Display + FromStr + PartialOrd<T>> ReadLine for RangeTo<T>

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

source§

impl<T: Display + FromStr + PartialOrd<T>> ReadLine for RangeToInclusive<T>

§

type Output = T

source§

fn try_read_line(&self) -> BoxResult<Self::Output>

Implementors§