NeoMutt  2021-02-05-666-ge300cd
Teaching an old dog new tricks
DOXYGEN
lib.h
Go to the documentation of this file.
1 
35 #ifndef MUTT_MBOX_LIB_H
36 #define MUTT_MBOX_LIB_H
37 
38 #include <stdbool.h>
39 #include <stdio.h>
40 #include <time.h>
41 #include "core/lib.h"
42 
43 struct stat;
44 
49 {
50  FILE *fp;
51  struct timespec atime;
52 
53  bool locked : 1;
54  bool append : 1;
55 };
56 
57 extern struct MxOps MxMboxOps;
58 extern struct MxOps MxMmdfOps;
59 
60 #define MMDF_SEP "\001\001\001\001\n"
61 
62 enum MxStatus mbox_check(struct Mailbox *m, struct stat *sb, bool check_stats);
63 enum MailboxType mbox_path_probe(const char *path, const struct stat *st);
64 void mbox_reset_atime(struct Mailbox *m, struct stat *st);
65 bool mbox_test_new_folder(const char *path);
66 
67 #endif /* MUTT_MBOX_LIB_H */
bool locked
is the mailbox locked?
Definition: lib.h:53
void mbox_reset_atime(struct Mailbox *m, struct stat *st)
Reset the access time on the mailbox file.
Definition: mbox.c:842
bool append
mailbox is opened in append mode
Definition: lib.h:54
Mbox-specific Account data -.
Definition: lib.h:48
bool mbox_test_new_folder(const char *path)
Test if an mbox or mmdf mailbox has new mail.
Definition: mbox.c:815
struct timespec atime
File&#39;s last-access time.
Definition: lib.h:51
struct MxOps MxMmdfOps
MMDF Mailbox - Implements MxOps -.
Definition: mbox.c:1861
Convenience wrapper for the core headers.
enum MxStatus mbox_check(struct Mailbox *m, struct stat *sb, bool check_stats)
A mailbox.
Definition: mailbox.h:81
MailboxType
Supported mailbox formats.
Definition: mailbox.h:43
Time value with nanosecond precision.
Definition: file.h:48
enum MailboxType mbox_path_probe(const char *path, const struct stat *st)
Is this an mbox Mailbox? - Implements MxOps::path_probe() -.
Definition: mbox.c:1633
FILE * fp
Mailbox file.
Definition: lib.h:50
MxStatus
Return values from mbox_check(), mbox_check_stats(), mbox_snc(), and mbox_close() ...
Definition: mxapi.h:75
struct MxOps MxMboxOps
Mbox Mailbox - Implements MxOps -.
Definition: mbox.c:1831
Definition: mxapi.h:103