imap-url.h revision 6ae6496c225238a2c55a8cd96744ad976c44a726
#ifndef IMAP_URL_H
#define IMAP_URL_H
struct imap_url {
/* server */
const char *host_name;
/* user */
const char *userid;
const char *auth_type;
/* mailbox */
const char *mailbox;
/* message part */
const char *section;
/* message list (uid == 0) */
const char *search_program;
/* urlauth */
const char *uauth_rumpurl;
const char *uauth_access_application;
const char *uauth_access_user;
const char *uauth_mechanism;
const unsigned char *uauth_token;
unsigned int have_host_ip:1;
unsigned int have_port:1;
unsigned int have_partial:1;
};
/*
* IMAP URL parsing
*/
enum imap_url_parse_flags {
/* Scheme part 'imap:' is already parsed externally. This implies that
this is an absolute IMAP URL. */
IMAP_URL_PARSE_SCHEME_EXTERNAL = 0x01,
/* Require relative URL (omitting _both_ scheme and authority), e.g.
/MAILBOX/;UID=uid or even ;UID=uid. This flag means that an absolute
URL makes no sense in this context. Relative URLs are allowed once a
base URL is provided to the parser. */
IMAP_URL_PARSE_REQUIRE_RELATIVE = 0x02,
/* Allow URLAUTH URL */
IMAP_URL_PARSE_ALLOW_URLAUTH = 0x04
};
/* Parses full IMAP URL */
struct imap_url *
/*
* IMAP URL construction
*/
#endif