1 /**
2  * @file
3  * Mailbox helper functions
4  *
5  * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
6  *
7  * @copyright
8  * This program is free software: you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License as published by the Free Software
10  * Foundation, either version 2 of the License, or (at your option) any later
11  * version.
12  *
13  * This program is distributed in the hope that it will be useful, but WITHOUT
14  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
15  * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
16  * details.
17  *
18  * You should have received a copy of the GNU General Public License along with
19  * this program.  If not, see <http://www.gnu.org/licenses/>.
20  */
21 
22 #ifndef MUTT_MUTT_MAILBOX_H
23 #define MUTT_MUTT_MAILBOX_H
24 
25 #include <stdbool.h>
26 
27 struct Buffer;
28 struct Mailbox;
29 struct stat;
30 
31 /* force flags passed to mutt_mailbox_check() */
32 #define MUTT_MAILBOX_CHECK_FORCE       (1 << 0)
33 #define MUTT_MAILBOX_CHECK_FORCE_STATS (1 << 1)
34 
35 int  mutt_mailbox_check       (struct Mailbox *m_cur, int force);
36 void mutt_mailbox_cleanup     (const char *path, struct stat *st);
37 bool mutt_mailbox_list        (void);
38 struct Mailbox *mutt_mailbox_next(struct Mailbox *m_cur, struct Buffer *s);
39 struct Mailbox *mutt_mailbox_next_unread(struct Mailbox *m_cur, struct Buffer *s);
40 bool mutt_mailbox_notify      (struct Mailbox *m_cur);
41 void mutt_mailbox_set_notified(struct Mailbox *m);
42 
43 #endif /* MUTT_MUTT_MAILBOX_H */
44