pub struct Email {Show 20 fields
pub id: String,
pub thread_id: Option<String>,
pub provider: Option<String>,
pub account_id: Option<String>,
pub subject: String,
pub from: String,
pub to: Vec<String>,
pub cc: Option<Vec<String>>,
pub bcc: Option<Vec<String>>,
pub body: String,
pub html: bool,
pub date: DateTime<FixedOffset>,
pub labels: Option<Vec<String>>,
pub is_read: bool,
pub is_starred: bool,
pub attachments: Option<Vec<AttachmentMeta>>,
pub snippet: Option<String>,
pub message_id: Option<String>,
pub in_reply_to: Option<String>,
pub references: Option<Vec<String>>,
}Expand description
Email : A single email message. The provider/accountId provenance fields tell clients which connected mail account this row came from (Gmail, Outlook, etc.) so multi-account list responses can be merged sensibly client-side.
Fields§
§id: String§thread_id: Option<String>§provider: Option<String>§account_id: Option<String>§subject: String§from: String§to: Vec<String>§cc: Option<Vec<String>>§bcc: Option<Vec<String>>§body: String§html: booltrue when body contains HTML, false for plain text.
date: DateTime<FixedOffset>§labels: Option<Vec<String>>§is_read: bool§is_starred: bool§attachments: Option<Vec<AttachmentMeta>>§snippet: Option<String>§message_id: Option<String>RFC 5322 Message-ID header.
in_reply_to: Option<String>RFC 5322 In-Reply-To header — the parent message id this message is a reply to.
references: Option<Vec<String>>RFC 5322 References header (ancestor chain).
Implementations§
Source§impl Email
impl Email
Sourcepub fn new(
id: String,
subject: String,
from: String,
to: Vec<String>,
body: String,
html: bool,
date: DateTime<FixedOffset>,
is_read: bool,
is_starred: bool,
) -> Email
pub fn new( id: String, subject: String, from: String, to: Vec<String>, body: String, html: bool, date: DateTime<FixedOffset>, is_read: bool, is_starred: bool, ) -> Email
A single email message. The provider/accountId provenance fields tell clients which connected mail account this row came from (Gmail, Outlook, etc.) so multi-account list responses can be merged sensibly client-side.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Email
impl<'de> Deserialize<'de> for Email
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Email
Auto Trait Implementations§
impl Freeze for Email
impl RefUnwindSafe for Email
impl Send for Email
impl Sync for Email
impl Unpin for Email
impl UnsafeUnpin for Email
impl UnwindSafe for Email
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more