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 "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".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 #ifndef __CSMSACCOUNT_H__
17 #define __CSMSACCOUNT_H__
25 class CMsvOffPeakTimes;
26 class CMsvScheduleSettings;
27 class CMsvSendErrorActions;
28 class CMsvSysAgentActions;
33 Stores SMS service and Schedule Send settings to Central Repository.
38 NONSHARABLE_CLASS (CSmsAccount) : public CBase, public MMsvSessionObserver
42 IMPORT_C static CSmsAccount* NewL();
43 IMPORT_C static CSmsAccount* NewLC();
44 IMPORT_C virtual ~CSmsAccount();
46 IMPORT_C void InitialiseDefaultSettingsL(CSmsSettings& aSmsSettings);
47 IMPORT_C void InitialiseDefaultSettingsL(CMsvScheduleSettings& aScheduleSettings, CMsvOffPeakTimes& aOffPeakTimes, CMsvSendErrorActions& aErrorActions, CMsvSysAgentActions& aSysAgentActions);
48 IMPORT_C void LoadSettingsL(CSmsSettings& aSmsSettings);
49 IMPORT_C void LoadSettingsL(CMsvScheduleSettings& aScheduleSettings, CMsvOffPeakTimes& aOffPeakTimes, CMsvSendErrorActions& aErrorActions, CMsvSysAgentActions& aSysAgentActions);
50 IMPORT_C void SaveSettingsL(const CSmsSettings& aSmsSettings) const;
51 IMPORT_C void SaveSettingsL(const CMsvScheduleSettings& aScheduleSettings, const CMsvOffPeakTimes& aOffPeakTimes, const CMsvSendErrorActions& aErrorActions, const CMsvSysAgentActions& aSysAgentActions) const;
56 void HandleSessionEventL(TMsvSessionEvent , TAny* , TAny* , TAny* );
57 CMsvSession& SessionL();
59 TMsvId CreateSmsServiceL();
61 #if (defined SYMBIAN_MESSAGESTORE_HEADER_BODY_USING_SQLDB)
62 void CreateHeaderStoreL();
65 enum TSmsSettingsCenRepId
68 ESmsServiceId = 0x00000000,
69 ESmsSettingsVersionId = 0x00000001,
70 ESmsSettingsMesssageVersionId = 0x00000002,
71 ESmsValidityPeriodId = 0x00000003,
72 ESmsValidityPeriodFormatId = 0x00000004,
73 ESmsAlphabetId = 0x00000005,
74 ESmsMsgFlagsId = 0x00000006,
75 ESmsMessageConversionId = 0x00000007,
76 ESmsFlagsId = 0x00000008,
77 ESmsStatusReportHandlingId = 0x00000009,
78 ESmsSpecialMessageHandlingId = 0x0000000A,
79 ESmsCommDbActionId = 0x0000000B,
80 ESmsDeliveryId = 0x0000000C,
81 ESmsDefaultSCId = 0x0000000D,
82 ESmsSCAddressesCountId = 0x0000000E,
83 ESmsBearerActionId = 0x0000000F,
84 ESmsBearerId = 0x00000010,
85 ESmsClass2FolderId = 0x00000020,
86 ESmsDescriptionLengthId = 0x00000030,
87 ESmsAccountNameId = 0x00000040,
89 ESmsSCAddressesPartialId = 0x00001000,
90 EMsgSMSTimeStampSettings = 0x000A0020
94 CMsvSession* iMsvSession;
95 CRepository* iRepository;
98 #endif // __CSMSACCOUNT_H__