|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Access class to SIM |
|
15 * Interface : Private, CVmbxSimHandler |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef C_VMBXSIMHANDLER_H |
|
21 #define C_VMBXSIMHANDLER_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <e32base.h> |
|
25 #include <voicemailboxdefs.h> |
|
26 #include "voicemailboxdefsinternal.h" |
|
27 |
|
28 |
|
29 // FORWARD DECLARATION |
|
30 class CVmbxPbkStore; |
|
31 class CVoiceMailboxEntry; |
|
32 |
|
33 |
|
34 // CLASS DECLARATION |
|
35 /** |
|
36 * Creates connection to Sim phonebook and handles data flow from/to it |
|
37 * |
|
38 * @lib vmbxengine.lib |
|
39 * @since S60 v5.2 |
|
40 */ |
|
41 NONSHARABLE_CLASS( CVmbxSimHandler ) : public CBase |
|
42 { |
|
43 |
|
44 public: // Constructors and destructor |
|
45 |
|
46 /** |
|
47 * Two-phased constructor. |
|
48 */ |
|
49 static CVmbxSimHandler* NewL(); |
|
50 |
|
51 /** |
|
52 * Destructor. |
|
53 */ |
|
54 virtual ~CVmbxSimHandler(); |
|
55 |
|
56 public: // New functions |
|
57 |
|
58 /** |
|
59 * Retrieves mailbox number from Sim |
|
60 * @since S60 v5.2 |
|
61 * @param in aEntry a data type of CVoiceMailboxEntry |
|
62 */ |
|
63 void GetL( CVoiceMailboxEntry& aEntry ); |
|
64 |
|
65 /** |
|
66 * Saves vmbx number to Sim |
|
67 * @since S60 v5.2 |
|
68 * @param in aEntry a data type of CVoiceMailboxEntry |
|
69 * @return Symbian OS error code (KErrNone if successful) |
|
70 */ |
|
71 TInt Save( const CVoiceMailboxEntry& aEntry ); |
|
72 |
|
73 /** |
|
74 * Returns sim write access info |
|
75 * @since S60 v5.2 |
|
76 * @return ETrue if Sim is writable |
|
77 **/ |
|
78 TBool IsWritable(); |
|
79 |
|
80 /** |
|
81 * @see RMobilePhoneStore::NotifyStoreEvent |
|
82 * |
|
83 * @since S60 v5.2 |
|
84 */ |
|
85 void NotifyStoreEvent( TRequestStatus& aStatus, |
|
86 TUint32& aEvent, |
|
87 TInt& aIndex ) const; |
|
88 /** |
|
89 * Retrieves Sim PhoneBook Type |
|
90 * @since S60 v5.2 |
|
91 * @return TVmbxSimPhonebookType |
|
92 */ |
|
93 TVmbxSimPhonebookType PhoneBookType(); |
|
94 |
|
95 /** |
|
96 * CancelAsyncRequest |
|
97 * @since S60 v5.2 |
|
98 * @param aReqToCancel Entry data |
|
99 */ |
|
100 void CancelAsyncRequest( TInt aReqToCancel ) const; |
|
101 |
|
102 protected: |
|
103 |
|
104 /** |
|
105 * C++ constructor. |
|
106 */ |
|
107 CVmbxSimHandler(); |
|
108 |
|
109 /** |
|
110 * By default Symbian 2nd phase constructor is private. |
|
111 */ |
|
112 void ConstructL(); |
|
113 |
|
114 private: // data |
|
115 |
|
116 /** |
|
117 * pbk store |
|
118 * Own. |
|
119 */ |
|
120 CVmbxPbkStore* iPbkStore; |
|
121 }; |
|
122 |
|
123 #endif // C_VMBXSIMHANDLER_H |