31 * class for handling mailbox folder data |
31 * class for handling mailbox folder data |
32 * |
32 * |
33 * @lib FSFWCommonLib |
33 * @lib FSFWCommonLib |
34 * @since S60 S60 v3.1 |
34 * @since S60 S60 v3.1 |
35 */ |
35 */ |
36 NONSHARABLE_CLASS ( CFSMailFolderBase ) : public CBase |
36 NONSHARABLE_CLASS ( CFSMailFolderBase ) : public CExtendableEmail |
37 { |
37 { |
38 public: |
38 public: |
39 |
39 |
40 /** |
40 /** |
41 * Two-phased constructor. |
41 * Two-phased constructor. |
42 * |
42 * |
43 * @param aFolderId folder id in plugin containing folder |
43 * @param aFolderId folder id in plugin containing folder |
44 */ |
44 */ |
45 IMPORT_C static CFSMailFolderBase* NewL( const TFSMailMsgId aFolderId ); |
45 IMPORT_C static CFSMailFolderBase* NewL(const TFSMailMsgId aFolderId); |
46 |
46 |
47 /** |
47 /** |
48 * Two-phased constructor. |
48 * Two-phased constructor. |
49 * |
49 * |
50 * @param aFolderId folder id in plugin containing folder |
50 * @param aFolderId folder id in plugin containing folder |
51 */ |
51 */ |
52 IMPORT_C static CFSMailFolderBase* NewLC( const TFSMailMsgId aFolderId ); |
52 IMPORT_C static CFSMailFolderBase* NewLC(const TFSMailMsgId aFolderId); |
53 |
53 |
54 /** |
54 /** |
55 * Destructor. |
55 * Destructor. |
56 * |
56 * |
57 */ |
57 */ |
58 IMPORT_C virtual ~CFSMailFolderBase(); |
58 IMPORT_C virtual ~CFSMailFolderBase(); |
59 |
59 |
60 /** |
60 /** |
61 * folder id accessor |
61 * folder id accessor |
62 * |
62 * |
63 * @return folder id |
63 * @return folder id |
64 */ |
64 */ |
65 IMPORT_C TFSMailMsgId GetFolderId() const; |
65 IMPORT_C TFSMailMsgId GetFolderId() const; |
66 |
66 |
67 /** |
67 /** |
68 * parent folder id accessor |
68 * parent folder id accessor |
69 * |
69 * |
70 * @return parent folder id |
70 * @return parent folder id |
71 */ |
71 */ |
72 IMPORT_C TFSMailMsgId GetParentFolderId() const; |
72 IMPORT_C TFSMailMsgId GetParentFolderId() const; |
73 |
73 |
74 /** |
74 /** |
75 * parent folder id mutator |
75 * parent folder id mutator |
76 * |
76 * |
77 * @param aFolderId parent folder id to be set |
77 * @param aFolderId parent folder id to be set |
78 */ |
78 */ |
79 IMPORT_C void SetParentFolderId( const TFSMailMsgId aFolderId ); |
79 IMPORT_C void SetParentFolderId( const TFSMailMsgId aFolderId ); |
80 |
80 |
81 /** |
81 /** |
82 * folder name accessor |
82 * folder name accessor |
83 * |
83 * |
84 * @return folder name |
84 * @return folder name |
85 */ |
85 */ |
86 IMPORT_C TDesC& GetFolderName() const; |
86 IMPORT_C TDesC& GetFolderName() const; |
87 |
87 |
88 /** |
88 /** |
89 * Folder name mutator. Note ! Some clients may ignore names set for |
89 * Folder name mutator. Note ! Some clients may ignore names set for |
90 * standard folders (TFSFolderType being EFSInbox, EFSOutbox, EFSDraftsFolder, |
90 * standard folders (TFSFolderType being EFSInbox, EFSOutbox, EFSDraftsFolder, |
91 * EFSSentFolder, or EFSDeleted) and display own localized names for them. |
91 * EFSSentFolder, or EFSDeleted) and display own localized names for them. |
92 * E.g. Email UI behaves this way. |
92 * E.g. Email UI behaves this way. |
93 * |
93 * |
94 * @param aFolderName folder name to be set |
94 * @param aFolderName folder name to be set |
95 */ |
95 */ |
96 IMPORT_C void SetFolderName( const TDesC& aFolderName ); |
96 IMPORT_C void SetFolderName(const TDesC& aFolderName); |
97 |
97 |
98 /** |
98 /** |
99 * folder type accessor |
99 * folder type accessor |
100 * |
100 * |
101 * @return folder type |
101 * @return folder type |
102 */ |
102 */ |
103 IMPORT_C TFSFolderType GetFolderType() const; |
103 IMPORT_C TFSFolderType GetFolderType() const; |
104 |
104 |
105 /** |
105 /** |
106 * folder type mutator |
106 * folder type mutator |
107 * |
107 * |
108 * @param aFolderType folder type to be set |
108 * @param aFolderType folder type to be set |
109 */ |
109 */ |
110 IMPORT_C void SetFolderType( const TFSFolderType aFolderType ); |
110 IMPORT_C void SetFolderType( const TFSFolderType aFolderType ); |
111 |
111 |
112 /** |
112 /** |
113 * returns id of mailbox containing this folder |
113 * returns id of mailbox containing this folder |
114 * |
114 * |
115 * @return mailbox id |
115 * @return mailbox id |
116 */ |
116 */ |
117 IMPORT_C TFSMailMsgId GetMailBoxId() const; |
117 IMPORT_C TFSMailMsgId GetMailBoxId() const; |
118 |
118 |
119 /** |
119 /** |
120 * folder mailbox id mutator |
120 * folder mailbox id mutator |
121 * |
121 * |
122 * @param aMailBoxId mailbox id to be set |
122 * @param aMailBoxId mailbox id to be set |
123 */ |
123 */ |
124 IMPORT_C void SetMailBoxId( const TFSMailMsgId aMailBoxId ); |
124 IMPORT_C void SetMailBoxId( const TFSMailMsgId aMailBoxId ); |
125 |
125 |
126 /** |
126 /** |
127 * returns message count contained by this folder |
127 * returns message count contained by this folder |
128 * |
128 * |
129 * @return message count |
129 * @return message count |
130 */ |
130 */ |
131 IMPORT_C TUint GetMessageCount() const; |
131 IMPORT_C TUint GetMessageCount() const; |
132 |
132 |
133 /** |
133 /** |
134 * returns unread message count contained by this folder |
134 * returns unread message count contained by this folder |
135 * |
135 * |
136 * @return unread message count |
136 * @return unread message count |
137 */ |
137 */ |
138 IMPORT_C TUint GetUnreadCount() const; |
138 IMPORT_C TUint GetUnreadCount() const; |
139 |
139 |
140 /** |
140 /** |
141 * returns unseen message count contained by this folder |
141 * returns unseen message count contained by this folder |
142 * |
142 * |
143 * @return unseen message count |
143 * @return unseen message count |
144 */ |
144 */ |
145 IMPORT_C TUint GetUnseenCount() const; |
145 IMPORT_C TUint GetUnseenCount() const; |
146 |
146 |
147 /** |
147 /** |
148 * returns subfolder count contained by this folder |
148 * returns subfolder count contained by this folder |
149 * |
149 * |
150 * @return subfolder count |
150 * @return subfolder count |
151 */ |
151 */ |
152 IMPORT_C TUint GetSubFolderCount() const; |
152 IMPORT_C TUint GetSubFolderCount() const; |
153 |
153 |
154 /** |
154 /** |
155 * set message count contained by this folder |
155 * set message count contained by this folder |
156 * |
156 * |
157 * @param aMessageCount message count |
157 * @param aMessageCount message count |
158 */ |
158 */ |
159 IMPORT_C void SetMessageCount( const TUint aMessageCount ); |
159 IMPORT_C void SetMessageCount( const TUint aMessageCount ); |
160 |
160 |
161 /** |
161 /** |
162 * set unread message count contained by this folder |
162 * set unread message count contained by this folder |
163 * |
163 * |
164 * @param aMessageCount unread message count |
164 * @param aMessageCount unread message count |
165 */ |
165 */ |
166 IMPORT_C void SetUnreadCount( const TUint aMessageCount ); |
166 IMPORT_C void SetUnreadCount( const TUint aMessageCount ); |
167 |
167 |
168 /** |
168 /** |
169 * set unseen message count contained by this folder |
169 * set unseen message count contained by this folder |
170 * |
170 * |
171 * @param aMessageCount unseen message count |
171 * @param aMessageCount unseen message count |
172 */ |
172 */ |
173 IMPORT_C void SetUnseenCount( const TUint aMessageCount ); |
173 IMPORT_C void SetUnseenCount( const TUint aMessageCount ); |
174 |
174 |
175 /** |
175 /** |
176 * set subfolder count contained by this folder |
176 * set subfolder count contained by this folder |
177 * |
177 * |
178 * @param subfolder count |
178 * @param subfolder count |
179 */ |
179 */ |
180 IMPORT_C void SetSubFolderCount( const TUint aMessageCount ); |
180 IMPORT_C void SetSubFolderCount( const TUint aMessageCount ); |
181 |
181 |
182 /** |
182 /** |
183 * blocks copying to this folder from given folder types |
183 * blocks copying to this folder from given folder types |
184 * |
184 * |
185 * @param aFolderTypes blocked folder types |
185 * @param aFolderTypes blocked folder types |
186 * @param aMailBoxStatus mailbox status (online / offline) when |
186 * @param aMailBoxStatus mailbox status (online / offline) when |
187 * blocking is done |
187 * blocking is done |
188 */ |
188 */ |
189 IMPORT_C void BlockCopyFromL( RArray<TFSFolderType> aFolderTypes, |
189 IMPORT_C void BlockCopyFromL( RArray<TFSFolderType> aFolderTypes, |
190 TFSMailBoxStatus aMailBoxStatus ); |
190 TFSMailBoxStatus aMailBoxStatus ); |
191 /** |
191 /** |
192 * blocks moving to this folder from given folder types |
192 * blocks moving to this folder from given folder types |
193 * |
193 * |
194 * @param aFolderTypes blocked folder types |
194 * @param aFolderTypes blocked folder types |
195 * @param aMailBoxStatus mailbox status (online / offline) when |
195 * @param aMailBoxStatus mailbox status (online / offline) when |
196 * blocking is done |
196 * blocking is done |
197 */ |
197 */ |
198 IMPORT_C void BlockMoveFromL( RArray<TFSFolderType> aFolderTypes, |
198 IMPORT_C void BlockMoveFromL( RArray<TFSFolderType> aFolderTypes, |
199 TFSMailBoxStatus aMailBoxStatus ); |
199 TFSMailBoxStatus aMailBoxStatus ); |
200 |
200 |
201 // <qmail> |
201 // <qmail> |
202 /** |
202 /** |
203 * returns nmfolder constructed with shared data, |
203 * returns nmfolder constructed with shared data, |
204 * ownership is transferred to caller |
204 * ownership is transferred to caller |