|
1 // Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // CLtsyCallControlHandler |
|
15 |
|
16 #ifndef __CLTSYDISPATCHCALLCONTROLHANDLER_H_ |
|
17 #define __CLTSYDISPATCHCALLCONTROLHANDLER_H_ |
|
18 |
|
19 //system include |
|
20 #include <e32std.h> |
|
21 #include <e32base.h> |
|
22 #include <ctsy/ltsy/mltsydispatchinterface.h> |
|
23 #include <ctsy/ltsy/mltsydispatchcallcontrolinterface.h> |
|
24 #include "misdispatchinterfacesupported.h" |
|
25 |
|
26 //user include |
|
27 #include "ltsymacros.h" |
|
28 |
|
29 |
|
30 // FORWARD DECLARATIONS |
|
31 class CATDialVoice; |
|
32 class CCtsyDispatcherCallback; |
|
33 class CGlobalPhonemanager; |
|
34 class CATWaitForCallHandler; |
|
35 class MLtsyUnsolicitedCommandObserver; |
|
36 class CUnsolicitedCommandCallControlHandler; |
|
37 |
|
38 /** |
|
39 * Implements interfaces from the CTSY Dispatcher. The CTSY Dispatcher uses these |
|
40 * interfaces to make requests to the Licensee LTSY. |
|
41 */ |
|
42 class CLtsyCallControlHandler : public CBase, |
|
43 public MIsDispatchInterfaceSupported, |
|
44 public MLtsyDispatchCallControlAnswer, |
|
45 public MLtsyDispatchCallControlHold, |
|
46 public MLtsyDispatchCallControlDialEmergency, |
|
47 public MLtsyDispatchCallControlStopDtmfTone, |
|
48 public MLtsyDispatchCallControlSetActiveAlsLine, |
|
49 public MLtsyDispatchCallControlSendDtmfTonesCancel, |
|
50 public MLtsyDispatchCallControlHangUp, |
|
51 public MLtsyDispatchCallControlResume, |
|
52 public MLtsyDispatchCallControlSetDynamicHscsdParams, |
|
53 public MLtsyDispatchCallControlDialVoice, |
|
54 public MLtsyDispatchCallControlTransfer, |
|
55 public MLtsyDispatchCallControlSendDtmfTones, |
|
56 public MLtsyDispatchCallControlGetIdentityServiceStatus, |
|
57 public MLtsyDispatchCallControlSwap, |
|
58 public MLtsyDispatchCallControlLoanDataPort, |
|
59 public MLtsyDispatchCallControlRecoverDataPort, |
|
60 public MLtsyDispatchCallControlStartDtmfTone, |
|
61 public MLtsyDispatchCallControlGetActiveAlsLine, |
|
62 public MLtsyDispatchCallControlDialData, |
|
63 public MLtsyDispatchCallControlQueryIsEmergencyNumber, |
|
64 public MLtsyDispatchCallControlGetAlsPpSupport, |
|
65 public MLtsyDispatchCallControlGetAlsBlockedStatus, |
|
66 public MLtsyDispatchCallControlSetAlsBlocked, |
|
67 public MLtsyDispatchCallControlGetLifeTime, |
|
68 public MLtsyDispatchCallControlTerminateErrorCall, |
|
69 public MLtsyDispatchCallControlTerminateAllCalls, |
|
70 public MLtsyDispatchCallControlGetCallForwardingIndicator, |
|
71 public MLtsyDispatchCallControlUpdateLifeTimer |
|
72 { |
|
73 public: |
|
74 |
|
75 virtual ~CLtsyCallControlHandler(); |
|
76 static CLtsyCallControlHandler* NewL(CCtsyDispatcherCallback& aCtsyDispatcherCallback, CGlobalPhonemanager* aGloblePhone); |
|
77 static CLtsyCallControlHandler* NewLC(CCtsyDispatcherCallback& aCtsyDispatcherCallback, CGlobalPhonemanager* aGloblePhone); |
|
78 |
|
79 virtual TBool IsInterfaceSupported(TLtsyDispatchInterfaceApiId aDispatchApiId); |
|
80 void IsCallbackIndicatorSupported(TLtsyDispatchIndIdGroup aIdGroup, TUint32& aIndIdBitMask); |
|
81 |
|
82 |
|
83 |
|
84 // From MLtsyDispatchCallControlAnswer |
|
85 virtual TInt HandleAnswerReqL(TInt aCallId, TBool aIsIsvCall); |
|
86 |
|
87 // From MLtsyDispatchCallControlHold |
|
88 virtual TInt HandleHoldReqL(TInt aCallId); |
|
89 |
|
90 // From MLtsyDispatchCallControlDialEmergency |
|
91 virtual TInt HandleDialEmergencyReqL(const TDes& aEmergencyNumber); |
|
92 |
|
93 // From MLtsyDispatchCallControlStopDtmfTone |
|
94 virtual TInt HandleStopDtmfToneReqL(TInt aCallId); |
|
95 |
|
96 // From MLtsyDispatchCallControlSetActiveAlsLine |
|
97 virtual TInt HandleSetActiveAlsLineReqL(RMobilePhone::TMobilePhoneALSLine aAlsLine); |
|
98 |
|
99 // From MLtsyDispatchCallControlSendDtmfTonesCancel |
|
100 virtual TInt HandleSendDtmfTonesCancelReqL(TInt aCallId); |
|
101 |
|
102 // From MLtsyDispatchCallControlHangUp |
|
103 virtual TInt HandleHangUpReqL(TInt aCallId, TInt aHangupCause); |
|
104 |
|
105 // From MLtsyDispatchCallControlResume |
|
106 virtual TInt HandleResumeReqL(TInt aCallId); |
|
107 |
|
108 // From MLtsyDispatchCallControlSetDynamicHscsdParams |
|
109 virtual TInt HandleSetDynamicHscsdParamsReqL(TInt aCallId, const RMobileCall::TMobileHscsdCallParamsV1& aHscsdParams); |
|
110 |
|
111 // From MLtsyDispatchCallControlDialVoice void CallbackCallControlDialVoiceComp(TInt aError, TInt aCallId); |
|
112 virtual TInt HandleDialVoiceReqL(RMobilePhone::TMobilePhoneALSLine aLine, const RMobilePhone::TMobileAddress& aDialledParty, const RMobileCall::TMobileCallParamsV1& aCallParamsV1, TBool aIsIsvCall, RMobileCall::TCallParamOrigin aCallOrigin, TBool aPerformFdnCheck); |
|
113 |
|
114 // From MLtsyDispatchCallControlTransfer |
|
115 virtual TInt HandleTransferReqL(TInt aHeldCallId, TInt aSecondCallId); |
|
116 |
|
117 // From MLtsyDispatchCallControlSendDtmfTones |
|
118 virtual TInt HandleSendDtmfTonesReqL(TInt aCallId, const TDesC &aTones); |
|
119 |
|
120 // From MLtsyDispatchCallControlGetIdentityServiceStatus |
|
121 virtual TInt HandleGetIdentityServiceStatusReqL(RMobilePhone::TMobilePhoneIdService aService); |
|
122 |
|
123 // From MLtsyDispatchCallControlSwap |
|
124 virtual TInt HandleSwapReqL(TInt aHeldCallId, TInt aConnectedCallId); |
|
125 |
|
126 // From MLtsyDispatchCallControlLoanDataPort |
|
127 virtual TInt HandleLoanDataPortSyncL(TInt aCallId, RCall::TCommPort& aCommPort); |
|
128 |
|
129 // From MLtsyDispatchCallControlRecoverDataPort |
|
130 virtual TInt HandleRecoverDataPortSyncL(TInt aCallId, RCall::TCommPort& aCommPort); |
|
131 |
|
132 // From MLtsyDispatchCallControlStartDtmfTone |
|
133 virtual TInt HandleStartDtmfToneReqL(TInt aCallId, const TChar& aTone); |
|
134 |
|
135 // From MLtsyDispatchCallControlGetActiveAlsLine |
|
136 virtual TInt HandleGetActiveAlsLineReqL(); |
|
137 |
|
138 // From MLtsyDispatchCallControlDialData |
|
139 virtual TInt HandleDialDataReqL(const RMobilePhone::TMobileAddress& aDialledParty, const RMobileCall::TMobileDataCallParamsV1& aCallParamsV1, TBool aPerformFdnCheck); |
|
140 |
|
141 // From MLtsyDispatchCallControlQueryIsEmergencyNumber |
|
142 virtual TInt HandleQueryIsEmergencyNumberSyncL(const TDesC& aNumber, TBool& aIsEmergencyNumber); |
|
143 |
|
144 // From MLtsyDispatchCallControlUpdateLifeTimer |
|
145 virtual TInt HandleUpdateLifeTimerReqL(TUint32 aDuration); |
|
146 |
|
147 // From MLtsyDispatchCallControlGetAlsPpSupport |
|
148 virtual TInt HandleGetAlsPpSupportL(); |
|
149 |
|
150 // From MLtsyDispatchCallControlGetAlsBlockedStatus |
|
151 virtual TInt HandleGetAlsBlockedStatusL(); |
|
152 |
|
153 // From MLtsyDispatchCallControlSetAlsBlocked |
|
154 virtual TInt HandleSetAlsBlockedL(RMmCustomAPI::TSetAlsBlock aBlocked); |
|
155 |
|
156 // From MLtsyDispatchCallControlGetLifeTime |
|
157 virtual TInt HandleGetLifeTimeL(); |
|
158 |
|
159 // From MLtsyDispatchCallControlTerminateErrorCall |
|
160 virtual TInt HandleTerminateErrorCallL(TInt aCallId); |
|
161 |
|
162 // From MLtsyDispatchCallControlTerminateAllCalls |
|
163 virtual TInt HandleTerminateAllCallsL(); |
|
164 |
|
165 // From MLtsyDispatchCallControlGetCallForwardingIndicatorStatus |
|
166 virtual TInt HandleGetCallForwardingIndicatorL(); |
|
167 |
|
168 public: |
|
169 MLtsyUnsolicitedCommandObserver* GetUnsolicitedCallControlHandler() const; |
|
170 |
|
171 private: |
|
172 |
|
173 CLtsyCallControlHandler(CCtsyDispatcherCallback& aCtsyDispatcherCallback, CGlobalPhonemanager* aGloblePhone); |
|
174 void ConstructL(); |
|
175 |
|
176 private: |
|
177 |
|
178 /** |
|
179 * Callback object in the CTSY Dispatcher. |
|
180 * |
|
181 * Used to complete a request back to the CTSY Dispatcher. |
|
182 */ |
|
183 CCtsyDispatcherCallback& iCtsyDispatcherCallback; |
|
184 |
|
185 //Not Owned |
|
186 CGlobalPhonemanager* iGloblePhone; |
|
187 |
|
188 //monitor incoming call |
|
189 CATWaitForCallHandler* iWaitForCall; |
|
190 |
|
191 //Process unsolicited command |
|
192 CUnsolicitedCommandCallControlHandler* iUnsolicitedHandler; |
|
193 |
|
194 //Emergency call |
|
195 CATDialVoice* iEmergencyCall; |
|
196 }; // class CLtsyCallControlHandler |
|
197 |
|
198 #endif // __CLTSYDISPATCHCALLCONTROLHANDLER_H_ |