NeoMutt  2021-02-05-89-gabe350
Teaching an old dog new tricks
DOXYGEN
lib.h
Go to the documentation of this file.
1 
40 #ifndef MUTT_MAILDIR_LIB_H
41 #define MUTT_MAILDIR_LIB_H
42 
43 #include <stdbool.h>
44 #include <stdio.h>
45 #include "core/lib.h"
46 #include "edata.h"
47 #include "mx.h"
48 
49 struct ConfigSet;
50 struct Email;
51 struct HeaderCache;
52 
53 extern bool C_MaildirTrash;
54 
55 extern struct MxOps MxMaildirOps;
56 extern struct MxOps MxMhOps;
57 
58 int maildir_check_empty (const char *path);
59 void maildir_gen_flags (char *dest, size_t destlen, struct Email *e);
60 bool maildir_msg_open_new (struct Mailbox *m, struct Message *msg, const struct Email *e);
61 FILE * maildir_open_find_message(const char *folder, const char *msg, char **newname);
62 void maildir_parse_flags (struct Email *e, const char *path);
63 struct Email *maildir_parse_message (enum MailboxType type, const char *fname, bool is_old, struct Email *e);
64 struct Email *maildir_parse_stream (enum MailboxType type, FILE *fp, const char *fname, bool is_old, struct Email *e);
65 bool maildir_sync_mailbox_message(struct Mailbox *m, int msgno, struct HeaderCache *hc);
66 bool maildir_update_flags (struct Mailbox *m, struct Email *e_old, struct Email *e_new);
67 int mh_check_empty (const char *path);
68 int mh_sync_mailbox_message (struct Mailbox *m, int msgno, struct HeaderCache *hc);
69 
70 #endif /* MUTT_MAILDIR_LIB_H */
maildir_sync_mailbox_message
bool maildir_sync_mailbox_message(struct Mailbox *m, int msgno, struct HeaderCache *hc)
Save changes to the mailbox.
Definition: maildir.c:928
Email::msgno
int msgno
Number displayed to the user.
Definition: email.h:87
mh_sync_mailbox_message
int mh_sync_mailbox_message(struct Mailbox *m, int msgno, struct HeaderCache *hc)
Save changes to the mailbox.
Definition: mh.c:738
maildir_parse_stream
struct Email * maildir_parse_stream(enum MailboxType type, FILE *fp, const char *fname, bool is_old, struct Email *e)
Parse a Maildir message.
Definition: maildir.c:864
maildir_gen_flags
void maildir_gen_flags(char *dest, size_t destlen, struct Email *e)
Generate the Maildir flags for an email.
Definition: maildir.c:178
Mailbox
A mailbox.
Definition: mailbox.h:81
MxOps
The Mailbox API.
Definition: mx.h:116
C_MaildirTrash
bool C_MaildirTrash
Config: Use the maildir 'trashed' flag, rather than deleting.
Definition: config.c:42
maildir_check_empty
int maildir_check_empty(const char *path)
Is the mailbox empty.
Definition: maildir.c:1021
Email::path
char * path
Path of Email (for local Mailboxes)
Definition: email.h:92
maildir_msg_open_new
bool maildir_msg_open_new(struct Mailbox *m, struct Message *msg, const struct Email *e)
Open a new message in a Mailbox - Implements MxOps::msg_open_new()
Definition: maildir.c:1458
MxMaildirOps
struct MxOps MxMaildirOps
Maildir Mailbox - Implements MxOps.
Definition: maildir.c:1616
edata.h
maildir_update_flags
bool maildir_update_flags(struct Mailbox *m, struct Email *e_old, struct Email *e_new)
Update the mailbox flags.
Definition: shared.c:124
MxMhOps
struct MxOps MxMhOps
MH Mailbox - Implements MxOps.
Definition: mh.c:1225
lib.h
mh_check_empty
int mh_check_empty(const char *path)
Is mailbox empty.
Definition: mh.c:161
maildir_open_find_message
FILE * maildir_open_find_message(const char *folder, const char *msg, char **newname)
Find a new.
Definition: maildir.c:974
HeaderCache
header cache structure
Definition: lib.h:85
maildir_parse_message
struct Email * maildir_parse_message(enum MailboxType type, const char *fname, bool is_old, struct Email *e)
Actually parse a maildir message.
Definition: maildir.c:908
ConfigSet
Container for lots of config items.
Definition: set.h:228
MailboxType
MailboxType
Supported mailbox formats.
Definition: mailbox.h:43
maildir_parse_flags
void maildir_parse_flags(struct Email *e, const char *path)
Parse Maildir file flags.
Definition: maildir.c:796
mx.h
Email
The envelope/body of an email.
Definition: email.h:37
Message
A local copy of an email.
Definition: mx.h:94