Trait mail_parser::BodyPart[][src]

pub trait BodyPart<'x>: Display {
    fn get_contents(&'x self) -> &'x [u8]
Notable traits for &'_ [u8]
impl<'_> Read for &'_ [u8]impl<'_> Write for &'_ mut [u8]
;
fn get_text_contents(&'x self) -> &'x str;
fn len(&self) -> usize;
fn is_text(&self) -> bool;
fn is_binary(&self) -> bool; fn is_empty(&self) -> bool { ... } }
Expand description

An inline Text or Binary body part.

Required methods

Returns the body part’s contents as a u8 slice

Returns the body part’s contents as a str

Returns the body part’s length

Returns true when the body part MIME type is text/*

Returns true when the part is not text

Provided methods

Returns true when the body part is empty

Implementors