#[non_exhaustive]pub enum Protocol {
Smtp,
Lmtp,
}Expand description
Transport protocol for the connection.
Determines the greeting command and DATA response handling. SMTP uses EHLO and returns one reply after DATA (RFC 5321 Section 3.1). LMTP uses LHLO and returns one reply per recipient after DATA (RFC 2033 Section 4.2).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Smtp
Standard SMTP (RFC 5321). Uses EHLO; one reply after DATA.
Lmtp
Local Mail Transfer Protocol (RFC 2033). Uses LHLO; one reply per recipient after DATA.
Trait Implementations§
impl Copy for Protocol
impl Eq for Protocol
impl StructuralPartialEq for Protocol
Auto Trait Implementations§
impl Freeze for Protocol
impl RefUnwindSafe for Protocol
impl Send for Protocol
impl Sync for Protocol
impl Unpin for Protocol
impl UnsafeUnpin for Protocol
impl UnwindSafe for Protocol
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