#include "config.h"
#include <stdio.h>
#include "private.h"
#include "mutt/lib.h"
#include "msg_set.h"
#include "sort.h"
Go to the source code of this file.
Functions | |
int | imap_sort_uid (const void *a, const void *b, void *sdata) |
Compare two UIDs - Implements sort_t -. | |
int | imap_make_msg_set (struct UidArray *uida, struct Buffer *buf, int *pos) |
Generate a compressed message set of UIDs. | |
int | imap_exec_msg_set (struct ImapAccountData *adata, const char *pre, const char *post, struct UidArray *uida) |
Execute a command using a set of UIDs. | |
Variables | |
int | ImapMaxCmdlen = 8192 |
Maximum length of IMAP commands before they must be split. | |
IMAP Message Sets.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file msg_set.c.
int imap_make_msg_set | ( | struct UidArray * | uida, |
struct Buffer * | buf, | ||
int * | pos | ||
) |
Generate a compressed message set of UIDs.
uida | Array of UIDs |
buf | Buffer for message set |
pos | Cursor used for multiple calls to this function |
num | Number of UIDs processed |
Compress a sorted list of UIDs, e.g.
1,2,3,4,6,8,9,10
becomes 1:4,6,8:10
Definition at line 73 of file msg_set.c.
int imap_exec_msg_set | ( | struct ImapAccountData * | adata, |
const char * | pre, | ||
const char * | post, | ||
struct UidArray * | uida | ||
) |
Execute a command using a set of UIDs.
adata | Imap Account data |
pre | Prefix commands |
post | Postfix commands |
uida | Sorted array of UIDs |
num | Number of messages sent |
-1 | Error |
Commands are of the form: TAG PRE MESSAGE-SET POST e.g. A01 UID COPY 1:4 MAILBOX
Definition at line 133 of file msg_set.c.
int ImapMaxCmdlen = 8192 |
Maximum length of IMAP commands before they must be split.
This is suggested in RFC7162 (dated 2014).