Struct Envelope
pub struct Envelope { /* private fields */ }Expand description
SMTP envelope with transport sender and recipients.
Implementations§
§impl Envelope
impl Envelope
pub const fn new(sender: EnvelopeSender) -> Envelope
pub const fn new(sender: EnvelopeSender) -> Envelope
Creates an envelope with no recipients.
pub fn with_recipient(self, recipient: EnvelopeRecipient) -> Envelope
pub fn with_recipient(self, recipient: EnvelopeRecipient) -> Envelope
Adds a recipient and returns the updated envelope.
pub fn push_recipient(&mut self, recipient: EnvelopeRecipient)
pub fn push_recipient(&mut self, recipient: EnvelopeRecipient)
Appends a recipient.
pub const fn sender(&self) -> &EnvelopeSender
pub const fn sender(&self) -> &EnvelopeSender
Returns the envelope sender.
pub fn recipients(&self) -> &[EnvelopeRecipient]
pub fn recipients(&self) -> &[EnvelopeRecipient]
Returns envelope recipients.
Trait Implementations§
impl Eq for Envelope
impl StructuralPartialEq for Envelope
Auto Trait Implementations§
impl Freeze for Envelope
impl RefUnwindSafe for Envelope
impl Send for Envelope
impl Sync for Envelope
impl Unpin for Envelope
impl UnsafeUnpin for Envelope
impl UnwindSafe for Envelope
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