1 // Copyright (c) 2004-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 the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 #ifndef __CEMAILACCOUNTS_H__
17 #define __CEMAILACCOUNTS_H__
25 class CImIAPPreferences;
26 class CImPop3Settings;
27 class CImImap4Settings;
28 class CImSmtpSettings;
30 class CImapSyncDownloadRules;
31 class CImapTransportBufferSizes;
32 class CImSmtpMobilitySettings;
35 Maximum size of email account name
40 const TInt KEmailAccountNameSize = 256;
43 Maximum number of entries allowed in the IAP list for a SMTP mobility account
48 const TInt KMaxSmtpMobilityAccountIAPListEntries = 32;
51 Identifier number for a POP email account.
57 typedef TInt TPopAccountId;
60 Identifier number for an IMAP email account.
66 typedef TInt TImapAccountId;
69 Identifier number for an SMTP email account.
75 typedef TInt TSmtpAccountId;
78 Identifier number for an SMTP moblity account.
83 typedef TInt TSmtpMobilityAccountId;
91 typedef RArray<TUint32> RArrayIAP;
94 Null or undefined SMTP account identifier
99 const TSmtpAccountId KNullSmtpAccountId = 0;
104 Objects of this type identify POP email accounts.
105 They are obtained when a POP account is created
106 (CEmailAccounts::CreatePopAccountL()), or by
107 querying for what POP accounts exist
108 (CEmailAccounts::GetPopAccountL() and CEmailAccounts::GetPopAccountsL()).
110 The object is then used as a handle to the account when getting
111 the account settings, using CEmailAccounts::LoadPopSettingsL() and
112 CEmailAccounts::LoadPopIapSettingsL().
120 /** POP account identifier number.
122 Each POP account stored on the phone has a different
123 identifier number to distinguish it from other accounts.
125 TPopAccountId iPopAccountId;
127 /** POP account name. */
128 TBuf<KEmailAccountNameSize> iPopAccountName;
130 /** Entry ID of the POP service for this account. */
133 /** Entry ID of the related SMTP service for this account.
135 This is set if an SMTP service has been created, using
136 CEmailAccounts::CreateSmtpAccountL(), that specifies that
137 it is related to this account. An SMTP service (which provides
138 email sending functionality) is used in conjunction with
139 a POP or IMAP service (which provide email retrieval).
147 Objects of this type identify IMAP email accounts.
148 They are obtained when a IMAP account is created
149 (CEmailAccounts::CreateImapAccountL()), or by
150 querying for what IMAP accounts exist
151 (CEmailAccounts::GetImapAccountL() and CEmailAccounts::GetImapAccountsL()).
153 The object is then used as a handle to the account when getting
154 the account settings, using CEmailAccounts::LoadImapSettingsL() and
155 CEmailAccounts::LoadImapIapSettingsL().
163 /** IMAP account identifier number.
165 Each IMAP account stored on the phone has a different
166 identifier number to distinguish it from other accounts.
168 TImapAccountId iImapAccountId;
170 /** IMAP account name */
171 TBuf<KEmailAccountNameSize> iImapAccountName;
173 /** Entry ID of the IMAP service for this account. */
176 /** Entry ID of the related SMTP service for this account.
178 This is set if an SMTP service has been created, using
179 CEmailAccounts::CreateSmtpAccountL(), that specifies that
180 it is related to this account. An SMTP service (which provides
181 email sending functionality) is used in conjunction with
182 a POP or IMAP service (which provide email retrieval).
190 Objects of this type identify SMTP email accounts.
191 They are obtained when a SMTP account is created
192 (CEmailAccounts::CreateSmtpAccountL()), or by
193 querying for what SMTP accounts exist
194 (CEmailAccounts::GetSmtpAccountL() and CEmailAccounts::GetISmtpAccountsL()).
196 The object is then used as a handle to the account when getting
197 the account settings, using CEmailAccounts::LoadSmtpSettingsL() and
198 CEmailAccounts::LoadSmtpIapSettingsL().
206 /** SMTP account identifier number. */
207 TSmtpAccountId iSmtpAccountId;
209 /** SMTP account name */
210 TBuf<KEmailAccountNameSize> iSmtpAccountName;
212 /** Entry ID of the SMTP service for this account. */
215 /** Entry ID of the related POP or IMAP service for this account.
217 An SMTP service (which provides email sending functionality) is
218 used in conjunction with a POP or IMAP service (which provide email retrieval).
220 TMsvId iRelatedService;
227 class TSmtpMobilityAccount
230 /** SMTP mobility account identifier */
231 TSmtpMobilityAccountId iAccountId;
233 /** SMTP mobility account name */
234 TBuf<KEmailAccountNameSize> iName;
236 /** Parent SMTP account identifier */
237 TSmtpAccountId iParentSmtpAccountId;
239 /** Linked SMTP account identifier. Identifies the SMTP account whose
240 settings will be used by this mobility account. If the mobility account
241 is using its own settings, this will be set to KNullSmtpAccountId. */
242 TSmtpAccountId iLinkedSmtpAccountId;
246 Creates, loads, saves and deletes email (IMAP, POP, and SMTP) accounts.
248 An account encapsulates:
250 - Settings for a messaging service. There is a different type of
251 settings class for each of the email protocols (CImPop3Settings,
252 CImImap4Settings, CImSmtpSettings).
253 - IAP (Internet account) settings for accessing the service.
255 The class has a family of functions for each protocol to create, get,
258 - Create\<protocol\>AccountL
259 - Get\<protocol\>AccountL
260 - Get\<protocol\>AccountsL
261 - Delete\<protocol\>AccountL
263 where \<protocol\> is either POP, IMAP, or SMTP.
264 The Create and Get functions don't directly return settings
265 objects, but only account identifiers.
267 Account identifiers are passed to the following functions
268 to save and load the service and IAP settings for that account:
270 - Load\<protocol\>SettingsL
271 - Save\<protocol\>SettingsL
272 - Load\<protocol\>IapSettingsL
273 - Save\<protocol\>IapSettingsL
275 For SMTP only, there is a concept of a default account (as a client
276 program may want to send an email, and not care which account is used.)
277 SetDefaultSmtpAccountL(), DefaultSmtpAccountL() and DeleteDefaultSmtpAccountL()
278 are used to handle this.
280 Note that an account is associated with a service entry in the message store,
281 but account information itself is stored in the central repository.
286 class CEmailAccounts : public CBase, public MMsvSessionObserver
290 IMPORT_C static CEmailAccounts* NewL();
291 IMPORT_C static CEmailAccounts* NewLC();
292 IMPORT_C virtual ~CEmailAccounts();
294 IMPORT_C TPopAccount CreatePopAccountL(const TDesC& aAccountName, const CImPop3Settings& aPopSettings,
295 const CImIAPPreferences& aPopIAP, TBool aReadOnly);
297 IMPORT_C TImapAccount CreateImapAccountL(const TDesC& aAccountName, const CImImap4Settings& aImapSettings,
298 const CImIAPPreferences& aImapIAP, TBool aReadOnly);
300 IMPORT_C TSmtpAccount CreateSmtpAccountL(TPopAccount& aPopAccount, const CImSmtpSettings& aSmtpSettings,
301 const CImIAPPreferences& aSmtpIAP, TBool aReadOnly);
303 IMPORT_C TSmtpAccount CreateSmtpAccountL(TImapAccount& aImapAccount, const CImSmtpSettings& aSmtpSettings,
304 const CImIAPPreferences& aSmtpIAP, TBool aReadOnly);
306 IMPORT_C TSmtpAccount CreateSmtpAccountL(const TDesC& aAccountName, const CImSmtpSettings& aSmtpSettings,
307 const CImIAPPreferences& aSmtpIAP, TBool aReadOnly);
309 IMPORT_C void GetPopAccountsL(RArray<TPopAccount>& aAccounts);
310 IMPORT_C void GetPopAccountL(TMsvId aServiceId, TPopAccount& aAccount);
311 IMPORT_C void DeletePopAccountL(const TPopAccount& aAccount);
313 IMPORT_C void GetImapAccountsL(RArray<TImapAccount>& aAccounts);
314 IMPORT_C void GetImapAccountL(TMsvId aServiceId, TImapAccount& aAccount);
315 IMPORT_C void DeleteImapAccountL(const TImapAccount& aAccount);
317 IMPORT_C void GetSmtpAccountsL(RArray<TSmtpAccount>& aAccounts);
318 IMPORT_C void GetSmtpAccountL(TMsvId aServiceId, TSmtpAccount& aAccount);
319 IMPORT_C void DeleteSmtpAccountL(const TSmtpAccount& aAccount);
320 IMPORT_C void DeleteDefaultSmtpAccountL();
322 IMPORT_C void PopulateDefaultPopSettingsL(CImPop3Settings& aPopSettings,
323 CImIAPPreferences& aPopIap);
325 IMPORT_C void PopulateDefaultImapSettingsL(CImImap4Settings& aImapSettings,
326 CImIAPPreferences& aImapIap);
328 IMPORT_C void PopulateDefaultSmtpSettingsL(CImSmtpSettings& aSmtpSettings,
329 CImIAPPreferences& aSmtpIap);
331 IMPORT_C TInt DefaultSmtpAccountL(TSmtpAccount& aAccount);
332 IMPORT_C void SetDefaultSmtpAccountL(const TSmtpAccount& aAccount);
334 IMPORT_C void LoadPopSettingsL(const TPopAccount& aAccount, CImPop3Settings& aPopSettings);
335 IMPORT_C void LoadPopIapSettingsL(const TPopAccount& aAccount, CImIAPPreferences& aIAP);
337 IMPORT_C void LoadImapSettingsL(const TImapAccount& aAccount, CImImap4Settings& aImapSettings);
338 IMPORT_C void LoadImapIapSettingsL(const TImapAccount& aAccount, CImIAPPreferences& aIAP);
340 IMPORT_C void LoadSmtpSettingsL(const TSmtpAccount& aAccount, CImSmtpSettings& aSmtpSettings);
341 IMPORT_C void LoadSmtpIapSettingsL(const TSmtpAccount& aAccount, CImIAPPreferences& aIAP);
343 IMPORT_C void SavePopSettingsL(const TPopAccount& aAccount, const CImPop3Settings& aPopSettings);
344 IMPORT_C void SavePopIapSettingsL(const TPopAccount& aAccount, const CImIAPPreferences& aIAP);
346 IMPORT_C void SaveImapSettingsL(const TImapAccount& aAccount, const CImImap4Settings& aImapSettings);
348 IMPORT_C void SaveImapIapSettingsL(const TImapAccount& aAccount, const CImIAPPreferences& aIAP);
350 IMPORT_C void SaveSmtpSettingsL(const TSmtpAccount& aAccount, const CImSmtpSettings& aSmtpSettings);
351 IMPORT_C void SaveSmtpIapSettingsL(const TSmtpAccount& aAccount, const CImIAPPreferences& aIAP);
353 IMPORT_C TBool IsAccountReadOnlyL(const TPopAccount& aAccount);
354 IMPORT_C TBool IsAccountReadOnlyL(const TImapAccount& aAccount);
355 IMPORT_C TBool IsAccountReadOnlyL(const TSmtpAccount& aAccount);
357 // Published partner routines
358 IMPORT_C TImapAccount CreateImapAccountL(const TDesC& aAccountName,
359 const CImImap4Settings& aImapSettings, const CImIAPPreferences& aImapIAP,
360 const CImapSyncDownloadRules& aSyncDownloadRules, TBool aReadOnly);
361 IMPORT_C void LoadImapSyncDownloadRulesL(const TImapAccount& aAccount, CImapSyncDownloadRules& aRules);
362 IMPORT_C void LoadImapTransportBufferSizesL(CImapTransportBufferSizes& aBufferSizes);
363 IMPORT_C void SaveImapSyncDownloadRulesL(const TImapAccount& aAccount, const CImapSyncDownloadRules& aRules);
364 IMPORT_C void SaveImapTransportBufferSizesL(const CImapTransportBufferSizes& aBufferSizes);
365 IMPORT_C void DeleteImapTransportBufferSizesL();
367 IMPORT_C void GetSmtpAccountL(TSmtpAccountId aAccountId, TSmtpAccount& aAccount);
369 IMPORT_C TSmtpMobilityAccount CreateSmtpMobilityAccountL(const TDesC& aAccountName, const RArrayIAP& aIapList, const TSmtpAccount& aSmtpAccount, const CImSmtpMobilitySettings& aSettings, TBool aReadOnly);
370 IMPORT_C TSmtpMobilityAccount CreateSmtpMobilityAccountL(const TDesC& aAccountName, const RArrayIAP& aIapList, const TSmtpAccount& aSmtpAccount, const TSmtpAccount& aLinkedSmtpAccount, TBool aReadOnly);
371 IMPORT_C void GetSmtpMobilityAccountsL(const TSmtpAccount& aSmtpAccount, RArray<TSmtpMobilityAccount>& aAccounts);
372 IMPORT_C void DeleteSmtpMobilityAccountL(const TSmtpMobilityAccount& aAccount);
374 IMPORT_C void PopulateDefaultSmtpMobilitySettingsL(CImSmtpMobilitySettings& aSettings);
375 IMPORT_C void LoadSmtpMobilitySettingsL(const TSmtpMobilityAccount& aAccount, CImSmtpMobilitySettings& aSettings);
376 IMPORT_C void SaveSmtpMobilitySettingsL(const TSmtpMobilityAccount& aAccount, const CImSmtpMobilitySettings& aSettings);
378 IMPORT_C void LoadSmtpMobilityAccountIapListL(const TSmtpMobilityAccount& aAccount, RArrayIAP& aIapList);
379 IMPORT_C void SaveSmtpMobilityAccountIapListL(const TSmtpMobilityAccount& aAccount, const RArrayIAP& aIapList);
381 IMPORT_C TBool IsAccountReadOnlyL(const TSmtpMobilityAccount& aAccount);
384 IMPORT_C void GetSmtpMobilityAccountsL(RArray<TSmtpMobilityAccount>& aAccounts);
385 IMPORT_C TBool LoadSmtpMobilitySettingsL(TSmtpAccountId& aSmtpAccountId, TUint32 aIap, CImSmtpMobilitySettings& aSettings);
389 void HandleSessionEventL(TMsvSessionEvent , TAny* , TAny* , TAny* );
390 CMsvSession& SessionL();
391 CRepository& PopRepositoryL();
392 CRepository& ImapRepositoryL();
393 CRepository& SmtpRepositoryL();
395 TMsvId CreateEmailServiceL(CMsvEntry& aMsvEntry, const TDesC& aAccountName, TUid aMTMType, TBool aVisible);
396 void SetRelatedIdL(CMsvEntry& aMsvEntry, TMsvId aId, TMsvId aRelatedId);
397 void SetEntryDetailsL(TMsvId aId, const TDesC& aAccountName);
398 void UnSetInPreparationFlagsL(CMsvEntry& aMsvEntry, TMsvId aId, TInt aAccountId);
399 void DeleteServiceEntryL(CMsvEntry& aMsvEntry, TMsvId aId);
401 TUint GetNextEmptyAccountSlotL(CRepository& aRepository);
402 TUint32 FindEmailAccountL(TMsvId aService, CRepository& aRepository);
404 void LoadIAPPrefSettingsL(TUint32 aAccountId, CImIAPPreferences& aIAP, CRepository& aRepository);
405 void DoLoadPopSettingsL(TUint32 aAccountId, CImPop3Settings& aPopSettings);
406 void DoLoadImapSettingsL(TUint32 aAccountId, CImImap4Settings& aImapSettings);
407 void DoLoadSmtpSettingsL(TUint32 aAccountId, CImSmtpSettings& aSmtpSettings);
409 void SaveIAPPrefSettingsL(TUint32 aAccountId, const CImIAPPreferences& aIAP, CRepository& aRepository);
410 void DoSavePopSettingsL(TUint32 aAccountId, const CImPop3Settings& aPopSettings);
411 void DoSaveSmtpSettingsL(TUint32 aAccountId, const CImSmtpSettings& aSmtpSettings);
412 void DoSaveImapSettingsL(TUint32 aAccountId, const CImImap4Settings& aImapSettings);
413 void DoSaveImapSyncDownloadRulesL(TUint32 aAccountId, const CImapSyncDownloadRules& aRules, CRepository& aRepository);
415 TImapAccount CreateImapAccountL(const TDesC& aAccountName, const CImImap4Settings& aImapSettings,
416 const CImIAPPreferences& aImapIAP, const CImapSyncDownloadRules* aSyncDownloadRules, TBool aReadOnly);
418 TUint32 DoCreatePopAccountL(const TDesC& aAccountName, const CImPop3Settings& aPopSettings,
419 const CImIAPPreferences& aPopIAP, TMsvId aPopService, TMsvId aRelatedService, TBool aReadOnly);
420 TUint32 DoCreateImapAccountL(const TDesC& aAccountName, const CImImap4Settings& aImapSettings,
421 const CImIAPPreferences& aImapIAP, const CImapSyncDownloadRules* aSyncDownloadRules, TMsvId aImapService,
422 TMsvId aRelatedService, TBool aReadOnly);
423 TUint32 DoCreateSmtpAccountL(TPopAccount& aPopAccount, const CImSmtpSettings& aSmtpSettings,
424 const CImIAPPreferences& aSmtpIAP, TMsvId aSmtpService, CMsvEntry& aMsvEntry, TUint32& aPopAccountId, TBool aReadOnly);
425 TUint32 DoCreateSmtpAccountL(TImapAccount& aImapAccount, const CImSmtpSettings& aSmtpSettings,
426 const CImIAPPreferences& aSmtpIAP, TMsvId aSmtpService, CMsvEntry& aMsvEntry, TUint32& aImapAccountId, TBool aReadOnly);
427 TUint32 DoCreateSmtpAccountL(const TDesC& aAccountName, const CImSmtpSettings& aSmtpSettings,
428 const CImIAPPreferences& aSmtpIAP, TMsvId aSmtpService, TMsvId aRelatedService, TBool aReadOnly);
430 void DeleteIAPPrefSettingsL(TUint32 aAccountId, CRepository& aRepository);
431 void DeletePopSettings(TUint32 aAccountId, CRepository& aRepository);
432 void DeleteSmtpSettings(TUint32 aAccountId, CRepository& aRepository);
433 void DeleteImapSettings(TUint32 aAccountId, CRepository& aRepository);
434 void DeleteImapSyncDownloadRulesL(TUint32 aAccountId, CRepository& aRepository);
436 void GetEmailServicesL(CMsvEntrySelection& aServices, TUid aMTMType, CMsvEntry& aMsvEntry);
438 TBool IsAsciiPrintable(const TDesC16& aText);
439 TBool IsAsciiPrintable(const TDesC8& aText);
440 TBool IsUnicodePrintable(const TDesC16& aText);
442 TSmtpMobilityAccount DoCreateSmtpMobilityAccountL(const TDesC& aAccountName, const RArrayIAP& aIapList, const CImSmtpMobilitySettings& aSettings, const TSmtpAccount& aSmtpAccount, TSmtpAccountId aLinkedSmtpAccountId, TBool aReadOnly);
443 void AddMobilityAccountToSmtpAccountL(const TSmtpAccount& aSmtpAccount, const RArrayIAP& aIapList, TUint32 aMobAccRepId, CRepository& aRepository);
444 void AddLinkToMobilityAccountL(TSmtpAccountId aLinkedSmtpAccountId, TUint32 aMobAccRepId, CRepository& aRepository);
445 TInt FindIapListEntryInSmtpMobilityAccountListL(const RArrayIAP& aIapList, CRepository& aRepository, TUint32 aSmtpAccRepId, TInt aNumEntries, TInt aIgnorePos);
446 TInt FindAccountIdInSmtpMobilityAccountListL(TUint32 aMobAccRepId, CRepository& aRepository, TUint32 aSmtpAccRepId, TInt aNumEntries);
447 void GetSmtpAccountInfoForMobilityAccountL(TUint32 aMobAccRepId, CRepository& aRepository, TUint32& aSmtpAccRepId, TInt& aPos);
448 void DeleteAllOwnedMobilityAccountsL(TUint32 aSmtpAccRepId, CRepository& aRepository);
449 void DeleteAllLinkedMobilityAccountsL(TUint32 aLinkedSmtpAccRepId, CRepository& aRepository);
450 void DeleteSmtpMobilityAccountListEntryL(TUint32 aMobAccRepId, CRepository& aRepository, TUint32 aSmtpAccRepId);
451 void DeleteSmtpMobilityAccountFromLinkedSmtpAccountL(TUint32 aMobAccRepId, CRepository& aRepository);
452 TBool IsSmtpTypeAccountReadOnlyL(TUint32 aAccRepId);
453 TBool IsSmtpMobilityAccount(CRepository& aRepository, TUint32 aAccRepId);
456 enum TEmailSettingTypes
458 // Partial CenRep Id for service settings
459 EServiceSettingType = 0x00000000,
460 // Partial CenRep Id for IAP Prefs
461 EIAPPrefSettingType = 0x00010000,
462 // CenRep mask for email accounts
463 EAccountMask = 0x800FFFFF
466 enum TPOPServiceSettingsCenRepId
468 EPOPServiceId = 0x00000000,
469 EPOPAccountNameId = 0x00000001,
470 EPOPRelatedSMTPServiceId = 0x00000002,
471 EPOPSettingsVersionId = 0x00000003,
472 EPOPServerAddressId = 0x00000004,
473 EPOPPortNumberId = 0x00000005,
474 EPOPFlagsId = 0x00000006,
475 EPOPLoginNameId = 0x00000007,
476 EPOPPasswordId = 0x00000008,
477 EPOPMaxEmailSizeId = 0x00000009,
478 EPOPGetEmailOptionsId = 0x0000000A,
479 EPOPInboxSynchronisationLimitId = 0x0000000B,
480 EPOPPopulationLimitId = 0x0000000C,
481 EPOPReadOnlyAccountId = 0x0000000D,
482 EPOPTlsSslDomainId = 0x0000000F
485 enum TIMAPServiceSettingsCenRepId
487 EIMAPServiceId = 0x00000000,
488 EIMAPAccountNameId = 0x00000001,
489 EIMAPRelatedSMTPServiceId = 0x00000002,
490 EIMAPSettingsVersionId = 0x00000003,
491 EIMAPServerAddressId = 0x00000004,
492 EIMAPPortNumberId = 0x00000005,
493 EIMAPFlagsId = 0x00000006,
494 EIMAPLoginNameId = 0x00000007,
495 EIMAPPasswordId = 0x00000008,
496 EIMAPFolderPathId = 0x00000009,
497 EIMAPPathSeparatorId = 0x0000000A,
498 EIMAPSynchronisationStrategyId = 0x0000000B,
499 EIMAPSubscriptionStrategyId = 0x0000000C,
500 EIMAPMaxEmailSizeId = 0x0000000D,
501 EIMAPGetMailOptionsId = 0x0000000E,
502 EIMAPInboxSynchronisationLimitId= 0x0000000F,
503 EIMAPMailboxSynchronisationLimitId= 0x00000010,
504 EIMAPTlsSslDomainId = 0x00000012,
505 EIMAPSyncRateId = 0x00000020,
506 EIMAPFetchSizeId = 0x00000030,
507 EIMAPIdleTimeoutId = 0x00000040,
508 EPartialMailOptionsId = 0x00000050,
509 EBodyTextSizeLimitId = 0x00000060,
510 EAttachmentSizeLimitId = 0x00000070,
511 EIMAPSearchStringId = 0x00000080,
512 EIMAPReadOnlyAccountId = 0x00000090,
513 // 0x00001000 - 0x00002FFF reserved for sync download rules
514 // 0x00010000 - 0x00014FFF reserved for IAP/SNAP preferences
517 enum TIMAPSyncDownloadRulesCenRepInfo
519 EIMAPSyncDownloadRulesVersionId = 0x00001000,
520 EIMAPNumInboxSyncDownloadRulesId = 0x00001001,
521 EIMAPNumFolderSyncDownloadRulesId = 0x00001002,
523 EIMAPInboxSyncDownloadRulesBearerTypesId = 0x00001010,
524 EIMAPInboxSyncDownloadRulesMailOptionsId = 0x00001011,
525 EIMAPInboxSyncDownloadRulesTotalSizeLimitId = 0x00001012,
526 EIMAPInboxSyncDownloadRulesBodyTextSizeLimitId = 0x00001013,
527 EIMAPInboxSyncDownloadRulesAttachmentSizeLimitId = 0x00001014,
528 EIMAPInboxSyncDownloadRulesGetMailBodyPartsId = 0x00001015,
529 EIMAPInboxSyncDownloadRulesMaxEmailSizeId = 0x00001016,
531 EIMAPFolderSyncDownloadRulesBearerTypesId = 0x00001030,
532 EIMAPFolderSyncDownloadRulesMailOptionsId = 0x00001031,
533 EIMAPFolderSyncDownloadRulesTotalSizeLimitId = 0x00001032,
534 EIMAPFolderSyncDownloadRulesBodyTextSizeLimitId = 0x00001033,
535 EIMAPFolderSyncDownloadRulesAttachmentSizeLimitId = 0x00001034,
536 EIMAPFolderSyncDownloadRulesGetMailBodyPartsId = 0x00001035,
537 EIMAPFolderSyncDownloadRulesMaxEmailSizeId = 0x00001036,
539 // Offset between sets of rules
540 EIMAPSyncDownloadRulesOffset = 0x40
543 enum TIAPPreferencesCenRepId
546 EIAPPrefVersion = 0x00010000,
547 EIAPChoicesCount = 0x00010001,
550 EIAPListIDs = 0x00011000,
551 EIAPListDialogPrefs = 0x00012000,
552 // EIAPSnapId placed here is a deviation from Design doc. Remove comment after a decision is made
553 EIAPSnapId = 0x00014000 // The same value is to be used in all account types
556 enum TIMAPTransportBufferSizesCenRepInfo
558 EIMAPTransportBufferSizesVersionId = 0x80000100,
559 EIMAPNumTransportBufferSizesId = 0x80000101,
561 EIMAPTransportBufferSizesBearerTypesId = 0x80000110,
562 EIMAPTransportBufferSizesFetchRequestSizeId = 0x80000111,
563 EIMAPTransportBufferSizesMaxOutstandingFetchResponsesId = 0x80000112,
565 // Offset between entries
566 EIMAPTransportBufferSizesOffset = 0x20
569 enum TSMTPServiceSettingsCenRepId
571 ESMTPServiceId = 0x00000000,
572 ESMTPAccountNameId = 0x00000001,
573 ESMTPSettingsVersionId = 0x00000002,
574 ESMTPServerAddressId = 0x00000003,
575 ESMTPPortNumberId = 0x00000004,
576 ESMTPFlagsId = 0x00000005,
577 ESMTPEmailAliasId = 0x00000006,
578 ESMTPEmailAddressId = 0x00000007,
579 ESMTPReplyToAddressId = 0x00000008,
580 ESMTPReceiptAddressId = 0x00000009,
581 ESMTPBodyEncodingId = 0x0000000A,
582 ESMTPDefaultMsgCharSetId = 0x0000000B,
583 ESMTPSendCopyToSelfId = 0x0000000C,
584 ESMTPSendMessageOptionId = 0x0000000D,
585 ESMTPLoginNameId = 0x0000000E,
586 ESMTPPasswordId = 0x0000000F,
587 ESMTPRelatedServiceId = 0x00000010,
588 ESMTPIncludeToCcId = 0x00000011,
589 ESMTPReadOnlyAccountId = 0x00000012,
590 ESMTPParentAccountId = 0x00000013,
591 ESMTPTlsSslDomainId = 0x00000014,
592 ESMTPLinkedAccountId = 0x00000015
595 enum TSMTPLinkedMobilityAccountListCenRepInfo
597 ESMTPLinkedMobilityAccountListVersionId = 0x00015000,
598 ESMTPLinkedMobilityAccountListNumEntriesId = 0x00015001,
599 ESMTPLinkedMobilityAccountListEntryId = 0x00015010,
601 // Maximum number of list entries
602 ESMTPLinkedMobilityAccountListMaxEntries = 2048
605 enum TSMTPMobilityAccountListCenRepInfo
607 ESMTPMobilityAccountListVersionId = 0x00016000,
608 ESMTPMobilityAccountListNumEntriesId = 0x00016001,
610 ESMTPMobilityAccountListAccountId = 0x00016010,
611 ESMTPMobilityAccountListNumIapsId = 0x00016011,
612 ESMTPMobilityAccountListIapId = 0x00016020,
614 // Offset between entries
615 ESMTPMobilityAccountListOffset = 0x40,
617 // Maximum number of list entries
618 ESMTPMobilityAccountMaxEntries = 32
622 CMsvSession* iMsvSession;
623 CRepository* iPOPRepository;
624 CRepository* iSMTPRepository;
625 CRepository* iIMAPRepository;
628 #endif // __CEMAILACCOUNTS_H__