pub struct MimeBodyInterpreter { /* private fields */ }
Available on crate feature
interpreter
only.Expand description
MIME → MML message body interpreter.
The interpreter follows the builder pattern, where the build function
is named interpret_*
.
Implementations§
Source§impl MimeBodyInterpreter
impl MimeBodyInterpreter
pub fn default_save_attachments_dir() -> PathBuf
pub fn new() -> Self
pub fn with_show_multiparts(self, visibility: bool) -> Self
pub fn with_show_parts(self, visibility: bool) -> Self
pub fn with_filter_parts(self, filter: FilterParts) -> Self
pub fn with_show_plain_texts_signature(self, visibility: bool) -> Self
pub fn with_show_attachments(self, visibility: bool) -> Self
pub fn with_show_inline_attachments(self, visibility: bool) -> Self
pub fn with_save_attachments(self, visibility: bool) -> Self
pub fn with_save_attachments_dir(self, dir: impl Into<PathBuf>) -> Self
Sourcepub async fn interpret_msg<'a>(&self, msg: &Message<'a>) -> Result<String>
pub async fn interpret_msg<'a>(&self, msg: &Message<'a>) -> Result<String>
Interpret the given MIME Message as a MML message string.
Sourcepub async fn interpret_bytes<'a>(
&self,
bytes: impl AsRef<[u8]> + 'a,
) -> Result<String>
pub async fn interpret_bytes<'a>( &self, bytes: impl AsRef<[u8]> + 'a, ) -> Result<String>
Interpret the given MIME message bytes as a MML message string.
Sourcepub async fn interpret_msg_builder<'a>(
&self,
builder: MessageBuilder<'a>,
) -> Result<String>
pub async fn interpret_msg_builder<'a>( &self, builder: MessageBuilder<'a>, ) -> Result<String>
Interpret the given MIME MessageBuilder as a MML message string.
Trait Implementations§
Source§impl Clone for MimeBodyInterpreter
impl Clone for MimeBodyInterpreter
Source§fn clone(&self) -> MimeBodyInterpreter
fn clone(&self) -> MimeBodyInterpreter
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MimeBodyInterpreter
impl Debug for MimeBodyInterpreter
Source§impl Default for MimeBodyInterpreter
impl Default for MimeBodyInterpreter
Source§impl PartialEq for MimeBodyInterpreter
impl PartialEq for MimeBodyInterpreter
impl Eq for MimeBodyInterpreter
impl StructuralPartialEq for MimeBodyInterpreter
Auto Trait Implementations§
impl Freeze for MimeBodyInterpreter
impl RefUnwindSafe for MimeBodyInterpreter
impl Send for MimeBodyInterpreter
impl Sync for MimeBodyInterpreter
impl Unpin for MimeBodyInterpreter
impl UnwindSafe for MimeBodyInterpreter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.