1 /* |
|
2 * Copyright (c) 2007 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: Utility class for waiting idle. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CTeleWaitingIdle_H |
|
20 #define CTeleWaitingIdle_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 #include <e32property.h> |
|
25 |
|
26 class CTeleRecoverySystem; |
|
27 |
|
28 // CLASS DECLARATION |
|
29 |
|
30 /** |
|
31 * Utility class for CTeleWaitingIdle. |
|
32 * |
|
33 * @lib - |
|
34 * @since S60 5.0 |
|
35 */ |
|
36 NONSHARABLE_CLASS( CTeleWaitingIdle ) : public CActive |
|
37 { |
|
38 public: // Constructors and destructor |
|
39 |
|
40 /** |
|
41 * Two-phased constructor. |
|
42 * @param aPriority priority for the timer. |
|
43 * @return new instance of CTeleWaitingIdle. |
|
44 */ |
|
45 static CTeleWaitingIdle* NewL( |
|
46 TInt aPriority, |
|
47 CTeleRecoverySystem& aRecoverySystem ); |
|
48 |
|
49 /** |
|
50 * Destructor. |
|
51 */ |
|
52 virtual ~CTeleWaitingIdle(); |
|
53 |
|
54 public: // New functions |
|
55 |
|
56 /** |
|
57 * The Callback function is called after the interval. |
|
58 * |
|
59 * @param anInterval interval. |
|
60 * @param aCallBack callback to be called after |
|
61 * interval. |
|
62 */ |
|
63 void StartWaitingIdleL(); |
|
64 |
|
65 protected: // Functions from base classes |
|
66 |
|
67 /** |
|
68 * @see CActive. |
|
69 */ |
|
70 virtual void RunL(); |
|
71 |
|
72 /** |
|
73 * @see CActive::DoCancel. |
|
74 */ |
|
75 void DoCancel(); |
|
76 |
|
77 private: // Constructors |
|
78 |
|
79 /** |
|
80 * C++ constructor. |
|
81 */ |
|
82 CTeleWaitingIdle( TInt aPriority, |
|
83 CTeleRecoverySystem& aRecoverySystem ); |
|
84 |
|
85 private: // Data |
|
86 |
|
87 // Timer callback. |
|
88 TCallBack iCallBack; |
|
89 |
|
90 // Central Repository. |
|
91 RProperty iProperty; |
|
92 |
|
93 // Recovery System. |
|
94 CTeleRecoverySystem& iRecoverySystem; |
|
95 }; |
|
96 |
|
97 #endif // CTeleWaitingIdle_H |
|
98 |
|
99 // End of File |
|