usecrate::config::TlsVerify;/// Abstraction over I/O for SMTP protocol operations.
////// Implement this trait to provide custom transport (e.g., for testing).
/// The ESP-IDF implementation is provided behind the `esp-idf` feature flag.
pubtraitSmtpTransport{/// The error type for transport operations.
typeError:std::error::Error +Send+Sync+'static;/// Read bytes from the connection into `buf`.
/// Returns the number of bytes read.
////// # Errors
////// Returns `Self::Error` on I/O or connection failure.
fnread(&mutself, buf:&mut [u8])->Result<usize, Self::Error>;/// Write all bytes in `data` to the connection.
////// # Errors
////// Returns `Self::Error` on I/O or connection failure.
fnwrite_all(&mutself, data:&[u8])->Result<(), Self::Error>;/// Upgrade the connection to TLS (for STARTTLS).
////// `host` is the server hostname for SNI.
/// `tls_verify` controls certificate verification.
////// # Errors
////// Returns `Self::Error` if the TLS handshake fails.
fnupgrade_tls(&mutself, host:&str, tls_verify:&TlsVerify)->Result<(), Self::Error>;}