Trait mail_parser::BodyPart [−][src]
pub trait BodyPart<'x>: Display {
fn get_header(&self) -> Option<&MimeHeader<'x>>;
fn get_contents(&'x self) -> &'x [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
fn get_header(&self) -> Option<&MimeHeader<'x>>
fn get_header(&self) -> Option<&MimeHeader<'x>>
Returns the MIME Header of the part
Returns the body part’s contents as a u8
slice
fn get_text_contents(&'x self) -> &'x str
fn get_text_contents(&'x self) -> &'x str
Returns the body part’s contents as a str