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: Class definition of DiagFwInternal::CEventBasic |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // CLASS DECLARATION |
|
20 #include "diagengineeventbasic.h" |
|
21 |
|
22 // SYSTEM INCLUDE FILES |
|
23 #include <DiagFrameworkDebug.h> |
|
24 |
|
25 // USER INCLUDE FILES |
|
26 #include "diagframework.pan" // Panic Codes. |
|
27 |
|
28 using namespace DiagFwInternal; |
|
29 |
|
30 // ======== LOCAL FUNCTIONS ======== |
|
31 |
|
32 |
|
33 // ======== MEMBER FUNCTIONS ======== |
|
34 |
|
35 // --------------------------------------------------------------------------- |
|
36 // CEventBasic::CEventBasic() |
|
37 // --------------------------------------------------------------------------- |
|
38 // |
|
39 CEventBasic::CEventBasic( TEvent aType ) |
|
40 : iType( aType ) |
|
41 { |
|
42 } |
|
43 |
|
44 // --------------------------------------------------------------------------- |
|
45 // CEventBasic::GetType() |
|
46 // --------------------------------------------------------------------------- |
|
47 // |
|
48 TEvent CEventBasic::GetType() const |
|
49 { |
|
50 return iType; |
|
51 } |
|
52 |
|
53 // --------------------------------------------------------------------------- |
|
54 // CEventBasic::ToString() |
|
55 // --------------------------------------------------------------------------- |
|
56 // |
|
57 const TDesC& CEventBasic::ToString() const |
|
58 { |
|
59 #if _DEBUG |
|
60 _LIT( KEventExecute, "EEventExecute" ); |
|
61 _LIT( KEventPlanCreated, "EEventPlanCreated" ); |
|
62 _LIT( KEventExecuteNext, "EEventExecuteNext" ); |
|
63 _LIT( KEventTestProgress, "EEventTestProgress" ); |
|
64 _LIT( KEventResumeToRunning, "EEventResumeToRunning" ); |
|
65 _LIT( KEventResumeToCreatingPlan,"EEventResumeToCreatingPlan" ); |
|
66 _LIT( KEventSkip, "EEventSkip" ); |
|
67 _LIT( KEventCancelAll, "EEventCancelAll" ); |
|
68 _LIT( KEventSuspend, "EEventSuspend" ); |
|
69 _LIT( KEventVoiceCallActive, "EEventVoiceCallActive" ); |
|
70 _LIT( KEventAllPluginsCompleted, "EEventAllPluginsCompleted" ); |
|
71 _LIT( KEventFinalized, "EEventFinalized" ); |
|
72 |
|
73 switch ( iType ) |
|
74 { |
|
75 case EEventExecute: |
|
76 return KEventExecute(); |
|
77 case EEventPlanCreated: |
|
78 return KEventPlanCreated(); |
|
79 case EEventExecuteNext: |
|
80 return KEventExecuteNext(); |
|
81 case EEventTestProgress: |
|
82 return KEventTestProgress(); |
|
83 case EEventResumeToRunning: |
|
84 return KEventResumeToRunning(); |
|
85 case EEventResumeToCreatingPlan: |
|
86 return KEventResumeToCreatingPlan(); |
|
87 case EEventSkip: |
|
88 return KEventSkip(); |
|
89 case EEventCancelAll: |
|
90 return KEventCancelAll(); |
|
91 case EEventSuspend: |
|
92 return KEventSuspend(); |
|
93 case EEventVoiceCallActive: |
|
94 return KEventVoiceCallActive(); |
|
95 case EEventAllPluginsCompleted: |
|
96 return KEventAllPluginsCompleted(); |
|
97 case EEventFinalized: |
|
98 return KEventFinalized(); |
|
99 default: |
|
100 Panic( EDiagFrameworkInternal ); |
|
101 break; |
|
102 } |
|
103 |
|
104 |
|
105 #endif // if _DEBUG |
|
106 |
|
107 _LIT( KEventDefaultName, "?" ); |
|
108 return KEventDefaultName(); |
|
109 } |
|
110 |
|
111 // End of File |
|
112 |
|