Trait nom8::input::AsBytes

source ·
pub trait AsBytes {
    // Required method
    fn as_bytes(&self) -> &[u8] ;
}
Expand description

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

Required Methods§

source

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

Casts the input type to a byte slice

Implementations on Foreign Types§

source§

impl<'a> AsBytes for &'a str

source§

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

source§

impl AsBytes for str

source§

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

source§

impl AsBytes for [u8]

source§

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

source§

impl<const LEN: usize> AsBytes for [u8; LEN]

source§

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

source§

impl<'a> AsBytes for &'a [u8]

source§

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

source§

impl<'a, const LEN: usize> AsBytes for &'a [u8; LEN]

source§

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

Implementors§

source§

impl<I> AsBytes for Located<I>where I: AsBytes,

source§

impl<I> AsBytes for Streaming<I>where I: AsBytes,

source§

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