[−][src]Struct mailstrom::Mailstrom
Methods
impl<S: MailstromStorage + 'static> Mailstrom<S>
[src]
pub fn new(config: Config, storage: S) -> Mailstrom<S>
[src]
Create a new Mailstrom instance for sending emails.
pub fn start(&mut self) -> Result<(), Error>
[src]
Mailstrom requires an explicit start command to start sending emails. This is because some clients are only interested in reading the status of sent emails, and will terminate before any real sending can be accomplished.
pub fn die(&mut self) -> Result<(), Error>
[src]
Ask Mailstrom to die. This is not required, you can simply let it fall out of scope and it will clean itself up.
pub fn worker_status(&self) -> WorkerStatus
[src]
Determine the status of the worker
pub fn send_email(&mut self, email: Email) -> Result<String, Error>
[src]
Send an email, getting back its message-id
pub fn query_status(&mut self, message_id: &str) -> Result<MessageStatus, Error>
[src]
pub fn query_recent(&mut self) -> Result<Vec<MessageStatus>, Error>
[src]
Trait Implementations
Auto Trait Implementations
impl<S> !RefUnwindSafe for Mailstrom<S>
impl<S> Send for Mailstrom<S>
impl<S> !Sync for Mailstrom<S>
impl<S> Unpin for Mailstrom<S>
impl<S> !UnwindSafe for Mailstrom<S>
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> TryFrom<T> for T
[src]
type Error = ParseError
The type returned in the event of a conversion error.
fn try_from(input: T) -> Result<T, <T as TryFrom<T>>::Error>
[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>,