mailslurp/models/
inbox_projection.rs1#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
15pub struct InboxProjection {
16 #[serde(rename = "createdAt")]
17 pub created_at: String,
18 #[serde(rename = "emailAddress", skip_serializing_if = "Option::is_none")]
19 pub email_address: Option<String>,
20 #[serde(rename = "favourite")]
21 pub favourite: bool,
22 #[serde(rename = "id")]
23 pub id: String,
24 #[serde(rename = "inboxType", skip_serializing_if = "Option::is_none")]
25 pub inbox_type: Option<InboxType>,
26 #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
27 pub name: Option<String>,
28 #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
29 pub tags: Option<Vec<String>>,
30 #[serde(rename = "teamAccess")]
31 pub team_access: bool,
32}
33
34impl InboxProjection {
35 pub fn new(created_at: String, favourite: bool, id: String, team_access: bool) -> InboxProjection {
36 InboxProjection {
37 created_at,
38 email_address: None,
39 favourite,
40 id,
41 inbox_type: None,
42 name: None,
43 tags: None,
44 team_access,
45 }
46 }
47}
48
49#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
51pub enum InboxType {
52 #[serde(rename = "HTTP_INBOX")]
53 HTTPINBOX,
54 #[serde(rename = "SMTP_INBOX")]
55 SMTPINBOX,
56}
57