|
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: This class implements MProEngProfile interface. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef CPROENGPROFILEIMPL_H |
|
21 #define CPROENGPROFILEIMPL_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <MProEngProfile.h> |
|
25 #include <e32base.h> |
|
26 |
|
27 // FORWARD DECLARATIONS |
|
28 class MProEngProfileName; |
|
29 class MProEngTones; |
|
30 class MProEngToneSettings; |
|
31 class MProfileExtended; |
|
32 class CProEngEngineImpl; |
|
33 class CProEngProfileNameImpl; |
|
34 class CProEngTonesImpl; |
|
35 class CProEngToneSettingsImpl; |
|
36 |
|
37 // CLASS DECLARATION |
|
38 |
|
39 /** |
|
40 * This class implements MProEngProfile interface. |
|
41 * |
|
42 * @lib ProfileEngine.lib |
|
43 * @since 3.1 |
|
44 */ |
|
45 NONSHARABLE_CLASS( CProEngProfileImpl ) : public CBase, |
|
46 public MProEngProfile |
|
47 { |
|
48 public: // Constructors and destructor |
|
49 |
|
50 /** |
|
51 * Two-phased constructor. |
|
52 * @param aProfileEngine wrapper for Profiles Engine. |
|
53 * @param aProfile private interface for Profiles data, ownership is |
|
54 * transferred. |
|
55 */ |
|
56 static CProEngProfileImpl* NewL( CProEngEngineImpl& aProfileEngine, |
|
57 MProfileExtended* aProfile ); |
|
58 |
|
59 /** |
|
60 * Destructor. |
|
61 */ |
|
62 virtual ~CProEngProfileImpl(); |
|
63 |
|
64 public: |
|
65 |
|
66 /** |
|
67 * From MProEngProfile |
|
68 */ |
|
69 void Release(); |
|
70 |
|
71 /** |
|
72 * From MProEngProfile |
|
73 */ |
|
74 const TArray<TContactItemId> AlertForL(); |
|
75 |
|
76 /** |
|
77 * From MProEngProfile |
|
78 */ |
|
79 TInt SetAlertForL( const TArray<TContactItemId>& aAlertFor ); |
|
80 |
|
81 /** |
|
82 * From MProEngProfile |
|
83 */ |
|
84 TBool IsSilent() const; |
|
85 |
|
86 /** |
|
87 * From MProEngProfile |
|
88 */ |
|
89 MProEngProfileName& ProfileName() const; |
|
90 |
|
91 /** |
|
92 * From MProEngProfile |
|
93 */ |
|
94 MProEngTones& ProfileTones() const; |
|
95 |
|
96 /** |
|
97 * From MProEngProfile |
|
98 */ |
|
99 MProEngToneSettings& ToneSettings() const; |
|
100 |
|
101 /** |
|
102 * From MProEngProfile |
|
103 */ |
|
104 void CommitChangeL(); |
|
105 |
|
106 private: |
|
107 |
|
108 /** |
|
109 * C++ constructor. |
|
110 */ |
|
111 CProEngProfileImpl( CProEngEngineImpl& aProfileEngine, |
|
112 MProfileExtended* aProfile ); |
|
113 |
|
114 /** |
|
115 * By default Symbian 2nd phase constructor is private. |
|
116 */ |
|
117 void ConstructL(); |
|
118 |
|
119 private: // Data |
|
120 |
|
121 // Ref: the Profiles Engine wrapper |
|
122 CProEngEngineImpl& iProfileEngine; |
|
123 |
|
124 // Own: the real implementation of the profile |
|
125 MProfileExtended* iProfile; |
|
126 |
|
127 // Own: profile name wrapper implementation |
|
128 CProEngProfileNameImpl* iProfileName; |
|
129 |
|
130 // Own: profile tones wrapper implementation |
|
131 CProEngTonesImpl* iTones; |
|
132 |
|
133 // Own: profile tone settings wrapper implementation |
|
134 CProEngToneSettingsImpl* iToneSettings; |
|
135 }; |
|
136 |
|
137 #endif // CPROENGPROFILEIMPL_H |
|
138 |
|
139 // End of File |
|
140 |