pub fn new_simple(domain: &str) -> Result<SmtpClient, Error> {
        let mut tls_builder = TlsConnector::builder();
        tls_builder.min_protocol_version(Some(DEFAULT_TLS_MIN_PROTOCOL));

        let tls_parameters =
            ClientTlsParameters::new(domain.to_string(), tls_builder.build().unwrap());

        SmtpClient::new(
            (domain, SUBMISSIONS_PORT),
            ClientSecurity::Wrapper(tls_parameters),
        )
    }
/// Simple and secure transport, should be used when possible.
/// Creates an encrypted transport over submissions port, using the provided domain
/// to validate TLS certificates.
Simple and secure transport, should be used when possible.
Creates an encrypted transport over submissions port, using the provided domain
to validate TLS certificates.
Simple and secure transport should be used when possible . Creates an encrypted transport over submissions port using the provided domain to validate TLS certificates .
pub fn new_simple(domain: &str) -> Result<SmtpClient, Error> {
        let mut tls_builder = TlsConnector::builder();
        tls_builder.min_protocol_version(Some(DEFAULT_TLS_MIN_PROTOCOL));
        let tls_parameters =
            ClientTlsParameters::new(domain.to_string(), tls_builder.build().unwrap());
        SmtpClient::new(
            (domain, SUBMISSIONS_PORT),
            ClientSecurity::Wrapper(tls_parameters),
        )
    }
pub fn new_simple ( domain : & str ) -> Result < SmtpClient , Error > { let mut tls_builder = TlsConnector :: builder ( ) ; tls_builder . min_protocol_version ( Some ( DEFAULT_TLS_MIN_PROTOCOL ) ) ; let tls_parameters = ClientTlsParameters :: new ( domain . to_string ( ) , tls_builder . build ( ) . unwrap ( ) ) ; SmtpClient :: new ( ( domain , SUBMISSIONS_PORT ) , ClientSecurity :: Wrapper ( tls_parameters ) , ) }
Simple and secure transport, should be used when possible.
Simple and secure transport should be used when possible .
domain
&str
domain
&str