1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
pub mod response;

use core::fmt;
use std::fmt::{Display, Formatter};

/// What Inbox you want to look at
pub enum WhereMessage {
    /// Everything
    Inbox,
    /// unread
    Unread,
    /// Sent
    SENT,
}

impl Display for WhereMessage {
    fn fmt(&self, f: &mut Formatter) -> fmt::Result {
        let string = match self {
            WhereMessage::Inbox => "inbox",
            WhereMessage::Unread => "unread",
            WhereMessage::SENT => "sent",
        };
        write!(f, "{}", string)
    }
}