pub trait Mode {
// Required methods
fn mail_id_max(&mut self) -> Result<usize, String>;
fn mail_id_list(
&mut self,
start_id: i32,
max_count: usize
) -> Result<Vec<String>, String>;
fn mail_id_get(&mut self, mail_id: i32) -> Result<String, String>;
fn send(&mut self) -> Result<Vec<u8>, String>;
fn set_from(&mut self, name: &str, mail: &str) -> &mut Self;
fn set_to(&mut self, name: &str, mail: &str) -> &mut Self;
fn set_cc(&mut self, name: &str, mail: &str) -> &mut Self;
fn set_subject(&mut self, subject: &str) -> &mut Self;
fn set_body(&mut self, text: &str, html: &str) -> &mut Self;
fn set_file(
&mut self,
name: &str,
data: Vec<u8>,
content_type: &str
) -> &mut Self;
}Required Methods§
sourcefn mail_id_max(&mut self) -> Result<usize, String>
fn mail_id_max(&mut self) -> Result<usize, String>
获取最大ID
sourcefn mail_id_list(
&mut self,
start_id: i32,
max_count: usize
) -> Result<Vec<String>, String>
fn mail_id_list( &mut self, start_id: i32, max_count: usize ) -> Result<Vec<String>, String>
获取指定量ID列表
sourcefn set_subject(&mut self, subject: &str) -> &mut Self
fn set_subject(&mut self, subject: &str) -> &mut Self
设置主题
Object Safety§
This trait is not object safe.