samotop-core 0.13.1+smtp

The domain model of Samotop and core functionality - SMTP server and library built on async-std. A base crate for samotop extensions.
Documentation
use crate::smtp::SmtpPath;
#[derive(Debug, Clone)]
pub struct Recipient {
    pub address: SmtpPath,
    pub certificate: Option<Certificate>,
}

#[derive(Debug, Clone)]
pub enum Certificate {
    File(String),
    Bytes(Vec<u8>),
}

impl Recipient {
    pub fn null() -> Self {
        Self::new(SmtpPath::Null)
    }
    pub fn new(address: SmtpPath) -> Self {
        Recipient {
            address,
            certificate: None,
        }
    }
}