dbox-storage.h revision ff3e079cdcd74e64eb35af0bc361e75d2ea03822
#ifndef DBOX_STORAGE_H
#define DBOX_STORAGE_H
#include "index-storage.h"
#include "mailbox-list-private.h"
#define DBOX_STORAGE_NAME "dbox"
#define DBOX_SUBSCRIPTION_FILE_NAME ".dbox-subscriptions"
#define DBOX_INDEX_PREFIX "dovecot.index"
#define DBOX_MAILDIR_NAME "dbox-Mails"
#define DBOX_INDEX_NAME "dbox.index"
#define DBOX_MAIL_FILE_MULTI_PREFIX "m."
#define DBOX_MAIL_FILE_UID_PREFIX "u."
/* How often to scan for stale temp files (based on dir's atime) */
/* Delete temp files having ctime older than this. */
/* Default rotation settings */
#define DBOX_DEFAULT_ROTATE_DAYS 0
#define DBOX_DEFAULT_MAX_OPEN_FILES 64
/* Flag specifies if the message should be in primary or alternative storage */
struct dbox_index_header {
};
struct dbox_storage {
struct mail_storage storage;
const char *alt_dir;
};
struct dbox_mail_index_record {
};
struct dbox_mailbox {
struct index_mailbox ibox;
struct dbox_storage *storage;
struct dbox_index *dbox_index;
/* timestamp when the mailbox was last modified interactively */
/* set while rebuilding indexes with converted maildir files */
unsigned int rotate_days;
unsigned int max_open_files;
};
struct dbox_transaction_context {
struct index_transaction_context ictx;
struct dbox_save_context *save_ctx;
};
extern struct mail_vfuncs dbox_mail_vfuncs;
void dbox_transaction_class_init(void);
void dbox_transaction_class_deinit(void);
struct mail *
dbox_mail_alloc(struct mailbox_transaction_context *t,
struct mailbox_header_lookup_ctx *wanted_headers);
#endif