|
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: |
|
15 * Declaration of CFotaCustCmdAllReasons class. |
|
16 * |
|
17 */ |
|
18 |
|
19 #ifndef FOTACUSTCMDALLREASONS_H |
|
20 #define FOTACUSTCMDALLREASONS_H |
|
21 |
|
22 #include <e32base.h> |
|
23 #include <ssm/ssmcustomcommand.h> |
|
24 |
|
25 /** |
|
26 * Each command is implemented in a class derived from MSsmCustomCommand. |
|
27 * It is also possible to implement multiple similar command in the same |
|
28 * class and differentiate between them based on constructor parameters |
|
29 * from the factory method. |
|
30 */ |
|
31 NONSHARABLE_CLASS( CFotaCustCmdAllReasons ) : public CBase, public MSsmCustomCommand |
|
32 { |
|
33 |
|
34 public: |
|
35 |
|
36 /** |
|
37 * Two-phased constructor |
|
38 */ |
|
39 static CFotaCustCmdAllReasons* NewL(); |
|
40 |
|
41 /** |
|
42 * Destructor |
|
43 */ |
|
44 virtual ~CFotaCustCmdAllReasons(); |
|
45 |
|
46 private: // From MSsmCustomCommand |
|
47 |
|
48 /** |
|
49 * @see MSsmCustomCommand |
|
50 */ |
|
51 TInt Initialize( CSsmCustomCommandEnv* aCmdEnv ); |
|
52 |
|
53 /** |
|
54 * @see MSsmCustomCommand |
|
55 */ |
|
56 void Execute( const TDesC8& aParams, TRequestStatus& aRequest ); |
|
57 |
|
58 /** |
|
59 * Takes action depending on the fota update state cenrep |
|
60 * @Params None |
|
61 * @return None |
|
62 * |
|
63 */ |
|
64 |
|
65 void ExecuteL( ); |
|
66 |
|
67 /** |
|
68 * @see MSsmCustomCommand |
|
69 */ |
|
70 void ExecuteCancel(); |
|
71 |
|
72 /** |
|
73 * @see MSsmCustomCommand |
|
74 */ |
|
75 void Close(); |
|
76 |
|
77 /** |
|
78 * @see MSsmCustomCommand |
|
79 */ |
|
80 void Release(); |
|
81 |
|
82 /** |
|
83 * Finds whether fota is schedduled or not |
|
84 * @Params None |
|
85 * @return |
|
86 * ETrue if fota is scheduled else EFalse |
|
87 */ |
|
88 TBool FindScheduleL(); |
|
89 |
|
90 private: // data |
|
91 |
|
92 /** |
|
93 * If the command needs command env in Execute function, it should store it |
|
94 * to member variable: |
|
95 * |
|
96 * Custom command environment. Not owned. Set in Initialize. |
|
97 * CSsmCustomCommandEnv* iEnv; |
|
98 */ |
|
99 |
|
100 /* |
|
101 * Function description: |
|
102 * This function checks for dmEventNotifier. |
|
103 * This checks for the specific scenario "when MMC is removed/inserted when phone is |
|
104 * in switch off mode. Then it starts the DmEventNotifier. |
|
105 * |
|
106 * @params: None |
|
107 * @Return: void |
|
108 */ |
|
109 void checkDMEventNotifierL(); |
|
110 |
|
111 }; |
|
112 |
|
113 #endif // FOTACUSTCMDALLREASONS_H |