pub struct ForwardTemplateBuilder<'a> {
pub interpreter: MimeInterpreterBuilder,
pub thread_interpreter: MimeInterpreterBuilder,
/* private fields */
}
Expand description
The message reply template builder.
This builder helps you to create a template in order to reply to an existing message.
Fields§
§interpreter: MimeInterpreterBuilder
Template interpreter instance.
thread_interpreter: MimeInterpreterBuilder
Template interpreter instance dedicated to the message thread.
Implementations§
Source§impl<'a> ForwardTemplateBuilder<'a>
impl<'a> ForwardTemplateBuilder<'a>
Sourcepub fn new(msg: &'a Message<'_>, config: Arc<AccountConfig>) -> Self
pub fn new(msg: &'a Message<'_>, config: Arc<AccountConfig>) -> Self
Creates a forward template builder from an account configuration and a message references.
Sourcepub fn with_headers(
self,
headers: impl IntoIterator<Item = (impl ToString, impl ToString)>,
) -> Self
pub fn with_headers( self, headers: impl IntoIterator<Item = (impl ToString, impl ToString)>, ) -> Self
Sets additional template headers following the builder pattern.
Sourcepub fn with_some_headers(
self,
headers: Option<impl IntoIterator<Item = (impl ToString, impl ToString)>>,
) -> Self
pub fn with_some_headers( self, headers: Option<impl IntoIterator<Item = (impl ToString, impl ToString)>>, ) -> Self
Sets some additional template headers following the builder pattern.
Sourcepub fn with_body(self, body: impl ToString) -> Self
pub fn with_body(self, body: impl ToString) -> Self
Sets the template body following the builder pattern.
Sourcepub fn with_some_body(self, body: Option<impl ToString>) -> Self
pub fn with_some_body(self, body: Option<impl ToString>) -> Self
Sets some template body following the builder pattern.
Sourcepub fn set_some_posting_style(
&mut self,
style: Option<impl Into<ForwardTemplatePostingStyle>>,
)
pub fn set_some_posting_style( &mut self, style: Option<impl Into<ForwardTemplatePostingStyle>>, )
Set some forward posting style.
Sourcepub fn set_posting_style(
&mut self,
style: impl Into<ForwardTemplatePostingStyle>,
)
pub fn set_posting_style( &mut self, style: impl Into<ForwardTemplatePostingStyle>, )
Set the forward posting style.
Sourcepub fn with_some_posting_style(
self,
style: Option<impl Into<ForwardTemplatePostingStyle>>,
) -> Self
pub fn with_some_posting_style( self, style: Option<impl Into<ForwardTemplatePostingStyle>>, ) -> Self
Set some forward posting style, using the builder pattern.
Sourcepub fn with_posting_style(
self,
style: impl Into<ForwardTemplatePostingStyle>,
) -> Self
pub fn with_posting_style( self, style: impl Into<ForwardTemplatePostingStyle>, ) -> Self
Set the forward posting style, using the builder pattern.
Sourcepub fn set_signature_style(
&mut self,
style: impl Into<ForwardTemplateSignatureStyle>,
)
pub fn set_signature_style( &mut self, style: impl Into<ForwardTemplateSignatureStyle>, )
Set the signature style.
Sourcepub fn set_some_signature_style(
&mut self,
style: Option<impl Into<ForwardTemplateSignatureStyle>>,
)
pub fn set_some_signature_style( &mut self, style: Option<impl Into<ForwardTemplateSignatureStyle>>, )
Set some signature style.
Sourcepub fn with_some_signature_style(
self,
style: Option<impl Into<ForwardTemplateSignatureStyle>>,
) -> Self
pub fn with_some_signature_style( self, style: Option<impl Into<ForwardTemplateSignatureStyle>>, ) -> Self
Set some signature style, using the builder pattern.
Sourcepub fn with_signature_style(
self,
style: impl Into<ForwardTemplateSignatureStyle>,
) -> Self
pub fn with_signature_style( self, style: impl Into<ForwardTemplateSignatureStyle>, ) -> Self
Set the signature style, using the builder pattern.
Sourcepub fn with_interpreter(self, interpreter: MimeInterpreterBuilder) -> Self
pub fn with_interpreter(self, interpreter: MimeInterpreterBuilder) -> Self
Sets the template interpreter following the builder pattern.
Sourcepub fn with_thread_interpreter(
self,
interpreter: MimeInterpreterBuilder,
) -> Self
pub fn with_thread_interpreter( self, interpreter: MimeInterpreterBuilder, ) -> Self
Sets the template thread interpreter following the builder pattern.
Auto Trait Implementations§
impl<'a> Freeze for ForwardTemplateBuilder<'a>
impl<'a> !RefUnwindSafe for ForwardTemplateBuilder<'a>
impl<'a> Send for ForwardTemplateBuilder<'a>
impl<'a> Sync for ForwardTemplateBuilder<'a>
impl<'a> Unpin for ForwardTemplateBuilder<'a>
impl<'a> !UnwindSafe for ForwardTemplateBuilder<'a>
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more