[−][src]Struct outlook_exe::MessageBuilder
The MessageBuilder
type, for drafting Outlook email messages.
Implementations
impl MessageBuilder
[src]
#[must_use]pub const fn new() -> Self
[src]
Creates a new MessageBuilder
.
#[must_use]pub fn with_subject<S>(self, subj: S) -> Self where
S: Into<String>,
[src]
S: Into<String>,
Adds a subject to the email.
This should only be called once per MessageBuilder
instance.
#[must_use]pub fn with_recipient<S>(self, to: S) -> Self where
S: Into<String>,
[src]
S: Into<String>,
Adds a recipient to the email.
#[must_use]pub fn with_recipient_cc<S>(self, cc: S) -> Self where
S: Into<String>,
[src]
S: Into<String>,
Adds a CC recipient to the email.
#[must_use]pub fn with_recipient_bcc<S>(self, bcc: S) -> Self where
S: Into<String>,
[src]
S: Into<String>,
Adds a BCC recipient to the email.
#[must_use]pub fn with_body<S>(self, body: S) -> Self where
S: Into<String>,
[src]
S: Into<String>,
Adds a body to the email.
This should only be called once per MessageBuilder
instance.
#[must_use]pub fn with_attachment<S>(self, file: S) -> Self where
S: Into<String>,
[src]
S: Into<String>,
Adds an attachment to the email.
This should only be called once per MessageBuilder
instance,
because Outlook's command-line switches only supports attaching
a single file per invocation.
pub fn spawn(self) -> Result<Child>
[src]
Spawns an Outlook process, and prompts the user to press "Send".
Errors
Will return Err(io::Error)
if OUTLOOK.EXE cannot
be located, or if a child process cannot be spawned.
Trait Implementations
impl Clone for MessageBuilder
[src]
fn clone(&self) -> MessageBuilder
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for MessageBuilder
[src]
impl Default for MessageBuilder
[src]
fn default() -> MessageBuilder
[src]
impl Eq for MessageBuilder
[src]
impl PartialEq<MessageBuilder> for MessageBuilder
[src]
fn eq(&self, other: &MessageBuilder) -> bool
[src]
fn ne(&self, other: &MessageBuilder) -> bool
[src]
impl StructuralEq for MessageBuilder
[src]
impl StructuralPartialEq for MessageBuilder
[src]
Auto Trait Implementations
impl RefUnwindSafe for MessageBuilder
impl Send for MessageBuilder
impl Sync for MessageBuilder
impl Unpin for MessageBuilder
impl UnwindSafe for MessageBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,