1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
use super::{MailboxStatistics, MailboxStatus}; pub trait MailboxProtocol { fn protocol_type(&self) -> u8; fn protocol_name(&self) -> &'static str; fn is_supported(&self) -> bool; fn last_status(&self) -> MailboxStatus { MailboxStatus::Pending } fn last_error_code(&self) -> u32 { 0 } fn statistics(&self) -> MailboxStatistics; fn reset_statistics(&self); }