|
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: Delegate notifications about profile modifications |
|
15 * to the observer. |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 #ifndef CPROENGPROFILEEVENTDELEGATE_H |
|
22 #define CPROENGPROFILEEVENTDELEGATE_H |
|
23 |
|
24 // INCLUDES |
|
25 #include "CProEngCenRepObserverBase.h" |
|
26 |
|
27 // FORWARD DECLARATIONS |
|
28 class MProEngProfileObserver; |
|
29 |
|
30 // CLASS DECLARATION |
|
31 |
|
32 /** |
|
33 * This class delegates notifications about profile modifications to the observer |
|
34 * implemented by the client of Profiles Engine Wrapper API. This is a helper |
|
35 * class for CProEngNotifyHandlerImpl. |
|
36 * |
|
37 * @lib ProfileEngine.lib |
|
38 * @since 3.1 |
|
39 */ |
|
40 NONSHARABLE_CLASS( CProEngProfileEventDelegate ) |
|
41 : public CProEngCenRepObserverBase |
|
42 { |
|
43 public: // constructor and destructor |
|
44 |
|
45 static CProEngProfileEventDelegate* NewL( |
|
46 TInt aProfileId, |
|
47 MProEngProfileObserver& aObserver ); |
|
48 |
|
49 virtual ~CProEngProfileEventDelegate() {}; |
|
50 |
|
51 public: // Functions from base classes |
|
52 |
|
53 /** |
|
54 * From CProEngObserverBase. |
|
55 */ |
|
56 void NotifyObserverL(); |
|
57 |
|
58 /** |
|
59 * From CProEngObserverBase. |
|
60 */ |
|
61 void NotifyError( TInt aError ); |
|
62 |
|
63 |
|
64 public: // New functions |
|
65 |
|
66 /** |
|
67 * Returns the ID of the profile observed by this class. |
|
68 */ |
|
69 TInt ProfileId() const; |
|
70 |
|
71 private: // constructor |
|
72 |
|
73 CProEngProfileEventDelegate( TUint32 aPartialCenRepKey, |
|
74 TUint32 aKeyMask, |
|
75 MProEngProfileObserver& aObserver ); |
|
76 |
|
77 private: // Data: |
|
78 |
|
79 // The client implemented observer for profile modification events: |
|
80 MProEngProfileObserver& iObserver; |
|
81 |
|
82 }; |
|
83 |
|
84 #endif // CPROENGPROFILEEVENTDELEGATE_H |
|
85 |
|
86 // End of File |
|
87 |