imapc-client.h revision 9fb018dea4e2073639249ea8a14ae27cab2c0aac
#ifndef IMAPC_CLIENT_H
#define IMAPC_CLIENT_H
enum imapc_command_state {
};
enum imapc_capability {
IMAPC_CAPABILITY_SASL_IR = 0x01,
IMAPC_CAPABILITY_LITERALPLUS = 0x02,
IMAPC_CAPABILITY_QRESYNC = 0x04,
IMAPC_CAPABILITY_IMAP4REV1 = 0x400000000
};
struct imapc_capability_name {
const char *name;
enum imapc_capability capability;
};
extern const struct imapc_capability_name imapc_capability_names[];
struct imapc_client_settings {
const char *host;
unsigned int port;
const char *master_user;
const char *username;
const char *password;
const char *dns_client_socket_path;
};
struct imapc_command_reply {
enum imapc_command_state state;
/* "RESP TEXT" when the reply contains [RESP TEXT], otherwise NULL */
const char *resp_text;
/* The full tagged reply, including [RESP TEXT]. */
const char *text;
};
struct imapc_untagged_reply {
/* name of the untagged reply, e.g. EXISTS */
const char *name;
/* number at the beginning of the reply, or 0 if there wasn't any.
Set for EXISTS, EXPUNGE, etc. */
/* the rest of the reply can be read from these args. */
/* "RESP TEXT" when the reply is "* OK [RESP TEXT]", otherwise NULL */
const char *resp_text;
/* If this reply occurred while a mailbox was selected, this contains
the mailbox's untagged_context. */
void *untagged_box_context;
};
/* Called when tagged reply is received for command. */
void *context);
/* Called each time untagged input is received. */
void *context);
struct imapc_client *
void *context);
struct imapc_client_mailbox *
void *untagged_box_context);
struct imapc_seqmap *
#endif