|
1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 #ifndef __TMESSAGEFLAGINFO_H__ |
|
17 #define __TMESSAGEFLAGINFO_H__ |
|
18 |
|
19 #include <e32std.h> |
|
20 |
|
21 |
|
22 /** |
|
23 Represents the flags of a server-side message |
|
24 @internalTechnology |
|
25 @prototype |
|
26 */ |
|
27 class TMessageFlagInfo |
|
28 { |
|
29 public: |
|
30 enum TImapMessageFlags { |
|
31 /** |
|
32 Message has been read |
|
33 */ |
|
34 ESeen = 0x1, |
|
35 /** |
|
36 Message has been answered |
|
37 */ |
|
38 EAnswered = 0x2, |
|
39 /** |
|
40 Message is "flagged" for urgent/special attention |
|
41 */ |
|
42 EFlagged = 0x4, |
|
43 /** |
|
44 Message is "deleted" for removal by later EXPUNGE |
|
45 */ |
|
46 EDeleted = 0x8, |
|
47 /** |
|
48 Message has not completed composition (marked as a draft). |
|
49 */ |
|
50 EDraft = 0x10, |
|
51 /** |
|
52 Message is "recently" arrived in this mailbox - can be affected by other sessions |
|
53 */ |
|
54 ERecent = 0x20 |
|
55 }; |
|
56 |
|
57 TMessageFlagInfo(); |
|
58 |
|
59 void SetFlag(TImapMessageFlags aFlagId, TBool aValue); |
|
60 IMPORT_C TBool QueryFlag(TImapMessageFlags aFlagId); |
|
61 |
|
62 TPtrC8 ParseFlagsL(const TDesC8& aFlagsData); |
|
63 TInt SetMessageUid(const TDesC8& aMessageUid); |
|
64 IMPORT_C TUint MessageUid() const; |
|
65 |
|
66 private: |
|
67 TUint iMessageUid; |
|
68 |
|
69 /** |
|
70 Bitwise combinaton of TImapMessageFlags. |
|
71 */ |
|
72 TUint8 iFlags; |
|
73 }; |
|
74 |
|
75 typedef RArray<TMessageFlagInfo> RArrayMessageFlagInfo; |
|
76 |
|
77 #endif // __TMESSAGEFLAGINFO_H__ |