2 * $Id: mailcmd.h 1142 2008-08-13 17:22:21Z hubert@u.washington.edu $
4 * ========================================================================
5 * Copyright 2013-2022 Eduardo Chappa
6 * Copyright 2006-2007 University of Washington
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * ========================================================================
17 #ifndef PITH_MAILCMD_INCLUDED
18 #define PITH_MAILCMD_INCLUDED
21 #include "../pith/state.h"
22 #include "../pith/msgno.h"
23 #include "../pith/context.h"
24 #include "../pith/indxtype.h"
27 #define EC_NONE 0x00 /* flags modifying expunge_and_close */
28 #define EC_NO_CLOSE 0x01 /* don't close at end */
36 #define MCMD_AGG_2 0x02
37 #define MCMD_SILENT 0x04
40 /* do_broach_folder flags */
41 #define DB_NOVISIT 0x01 /* this is a preopen, not a real visit */
42 #define DB_FROMTAB 0x02 /* opening because of TAB command */
43 #define DB_INBOXWOCNTXT 0x04 /* interpret inbox as one true inbox */
47 * generic "is aggregate message command?" test
49 #define MCMD_ISAGG(O) ((O) & (MCMD_AGG | MCMD_AGG_2))
52 /* exported prototypes */
53 int any_messages(MSGNO_S
*, char *, char *);
54 void bogus_utf8_command(char *, char *);
55 int can_set_flag(struct pine
*, char *, int);
56 void cmd_cancelled(char *);
57 void cmd_quota(struct pine
*);
58 int cmd_delete(struct pine
*, MSGNO_S
*, int, char *(*)(struct pine
*, MSGNO_S
*));
59 int cmd_undelete(struct pine
*, MSGNO_S
*, int);
60 int cmd_expunge_work(MAILSTREAM
*, MSGNO_S
*, char *);
61 CONTEXT_S
*broach_get_folder(CONTEXT_S
*, int *, char **);
62 int do_broach_folder(char *, CONTEXT_S
*, MAILSTREAM
**, unsigned long);
63 void expunge_and_close(MAILSTREAM
*, char **, unsigned long);
64 void agg_select_all(MAILSTREAM
*, MSGNO_S
*, long *, int);
65 char *move_read_msgs(MAILSTREAM
*, char *, char *, size_t, long);
66 char *move_read_incoming(MAILSTREAM
*, CONTEXT_S
*, char *, char **, char *, size_t);
67 void cross_delete_crossposts(MAILSTREAM
*);
68 long zoom_index(struct pine
*, MAILSTREAM
*, MSGNO_S
*, int);
69 int unzoom_index(struct pine
*, MAILSTREAM
*, MSGNO_S
*);
70 int agg_text_select(MAILSTREAM
*, MSGNO_S
*, char, char *, int, int, char *,
71 char *, SEARCHSET
**);
72 int agg_flag_select(MAILSTREAM
*, int, int, SEARCHSET
**);
73 char *get_uname(char *, char *, int);
74 int expand_foldername(char *, size_t);
77 #endif /* PITH_MAILCMD_INCLUDED */