1MAIL::ACCOUNT::SAVEF(3x)Cone: COnsole Newsreader And EMAIL::ACCOUNT::SAVEF(3x)
2
3
4
6 mail::account::saveFolderIndexInfo - Update message status
7
9 #include <libmail/mail.H>
10
11
12 class myCallback : public mail::callback {
13 public:
14 void success(std::string msg);
15 void fail(std::string msg);
16 };
17
18 mail::account *account;
19
20 account->saveFolderIndexInfo(size_t messageNum,
21 const messageInfo &msgInfo,
22 myCallback &callback);
23
25 mail::account::saveFolderIndexInfo changes the status of a message.
26 messageNum must be between zero and one less than the return code from
27 mail::account::getFolderIndexSize(3x). msgInfo contains the new status
28 flags for this message. See mail::account::getFolderIndexInfo(3x) for a
29 description of message status flags.
30
31 Note
32 The uid field in msgInfo is ignored. The message is specified by
33 messageNum, and unique IDs of existing messages cannot be changed.
34
36 The application must wait until callback´s success or fail method is
37 invoked. The success method is invoked when this request is succesfully
38 processed. The fail method is invoked if this request cannot be
39 processed. The application must not destroy callback until either the
40 success or fail method is invoked.
41
42 Note
43 callback´s fail method may be invoked even after other callback
44 methods were invoked. This indicates that the request was partially
45 completed before the error was encountered.
46
47 Note
48 The application is notified about when a message´s status changes
49 by by invoking the messageChanged callback method of the currently
50 opened folder´s mail::folderCallback object. Depending on the mail
51 server, the messageChanged method may be invoked as part of
52 processing this request, or some time later after this request is
53 completed, and callback´s success method was invoked.
54
55 Note
56 Multiple applications may have the same account and folder opened
57 at the same time. It is possible that a message referenced by this
58 request was already deleted by another application. Depending on
59 the underlying server implementation this will result in either a
60 failed request, invoking callback.fail, or the request completing
61 (callback.success invoked) but without invoking any callback
62 function that refer to the message.
63
65 mail::account::removeMessages(3x),
66 mail::account::updateFolderIndexFlags(3x),
67 mail::account::updateFolderIndexInfo(3x),
68 mail::account::getFolderIndexInfo(3x).
69
70
71
72[FIXME: source] 05/08/2010 MAIL::ACCOUNT::SAVEF(3x)