1mail::ACCOUNT::updatemFaoilld:e:rAICnCdOeUxNFTlaSgysn(cm3haxri)oln:o:uAsCCAOPUINTr:e:fueprdeantceeFolderIndexFlags(3x)
2
3
4
6 mail::ACCOUNT::updateFolderIndexFlags - Update status of multiple mes‐
7 sages
8
10 #include <libmail/sync.H>
11
12 mail::ACCOUNT *mail;
13
14
15
16 bool ok=mail->updateFolderIndexFlags (const std::vector<size_t>
17 msgList, bool doFlip, bool enableDisable, const messageInfo &msgInfo);
18
19 std::string errmsg=mail->getErrmsg();
20
22 This is a version of mail::ACCOUNT::saveFolderIndexInfo(3x) that
23 updates the status of multiple messages with one request.
24
25 msgList specifies a list of messages. Messages are numbered starting
26 with message #0 and up to one less than mail::ACCOUNT::getFolderIndex‐
27 Size(3x) (when mail::account::getFolderIndexSize returns 6, the mes‐
28 sages are numbered 0 through 5). Only the messages that appear in
29 msgList are processed by this request. When a message is removed from
30 the folder, by mail::ACCOUNT::updateFolderIndexInfo(3x), the following
31 messages are renumbered accordingly.
32
33 Note: Most mail servers allow multiple applications to open the
34 same folder. Therefore, changes to the folder's contents can
35 occur at any time. Before making this request, the application
36 should use mail::ACCOUNT::checkNewMail(3x) to verify that no
37 unexpected changes have been made to the folder's contents.
38
39 msgInfo selects which message status flags should be updated in every
40 message. See mail::ACCOUNT::getFolderIndexInfo(3x).
41
42 msgInfo does NOT specify the new value of the status flags, only which
43 status flags should be updated. For example, setting msgInfo.marked to
44 true indicates that the messages' marked status flag will be set to the
45 value specified by doFlip and enableDisable.
46
47 Setting doFlip to true "flips" the selected status flags (each mes‐
48 sage's flag will be set to false if the status flag was originally
49 true, and set to true if the status flag was originalfalse). If doFlip
50 is false, then the selected status flags are set to the value of
51 enableDisable enableDisable is ignored when Setting doFlip is true.
52
54 This method returns true if it succeeds, or false if it fails. If the
55 method fails, use mail::ACCOUNT::getErrmsg() to read a brief descrip‐
56 tion of the error.
57
59 mail::ACCOUNT::saveFolderIndexInfo(3x), mail::ACCOUNT::getFolderIndex‐
60 Info(3x).
61
62
63
64 10 Apmraiill:2:0A0C6COUNT::updateFolderIndexFlags(3x)