equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2006 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: Declaration of CNcdDelay class. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef C_NCDDELAY_H |
|
20 #define C_NCDDELAY_H |
|
21 |
|
22 #include <e32base.h> |
|
23 |
|
24 /** |
|
25 * Utility for creating delays and timer callbacks. |
|
26 * When a delay or timer callback is active, the thread is not stopped |
|
27 * and active scheduler events occur normally. |
|
28 */ |
|
29 class CNcdDelay : public CTimer |
|
30 { |
|
31 public: |
|
32 |
|
33 /** |
|
34 * Constructor. |
|
35 * |
|
36 * @param aCallBack Function that gets called after the timer goes off. |
|
37 * @return COsmDelay* Pointer to the created COsmDelay object. |
|
38 */ |
|
39 static CNcdDelay* CNcdDelay::NewL( TCallBack aCallBack ); |
|
40 |
|
41 private: |
|
42 |
|
43 /** |
|
44 * Constructor. |
|
45 * |
|
46 * @param aCallBack Function that gets called after timer goes off. |
|
47 */ |
|
48 CNcdDelay( TCallBack aCallBack ); |
|
49 |
|
50 /** |
|
51 * @see CActive::RunL() |
|
52 */ |
|
53 void RunL(); |
|
54 |
|
55 private: |
|
56 /** |
|
57 * Callback function |
|
58 */ |
|
59 TCallBack iCallBack; |
|
60 }; |
|
61 |
|
62 #endif |