devela::_dep::winnow::stream

Trait AsBStr

pub trait AsBStr {
    // Required method
    fn as_bstr(&self) -> &[u8] ;
}
Available on crate feature dep_winnow only.
Expand description

Helper trait for types that can be viewed as a byte slice

Required Methods§

fn as_bstr(&self) -> &[u8]

Casts the input type to a byte slice

Implementations on Foreign Types§

§

impl AsBStr for &str

§

fn as_bstr(&self) -> &[u8]

§

impl AsBStr for &[u8]

§

fn as_bstr(&self) -> &[u8]

Implementors§

§

impl AsBStr for &BStr

§

impl<I> AsBStr for LocatingSlice<I>
where I: AsBStr,

§

impl<I> AsBStr for Partial<I>
where I: AsBStr,

§

impl<I, S> AsBStr for Stateful<I, S>
where I: AsBStr,