|
1 // Copyright (c) 2008-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 // |
|
15 |
|
16 /** |
|
17 @file |
|
18 @internalAll |
|
19 */ |
|
20 |
|
21 #ifndef __CSUPPLEMENTARYSERVICESDISPATCHER_H_ |
|
22 #define __CSUPPLEMENTARYSERVICESDISPATCHER_H_ |
|
23 |
|
24 // INCLUDES |
|
25 #include <e32std.h> |
|
26 #include <e32base.h> |
|
27 #include <e32def.h> |
|
28 #include <etelmm.h> |
|
29 #include <mmlist.h> |
|
30 #include <ctsy/rmmcustomapi.h> |
|
31 |
|
32 #include <ctsy/ltsy/mltsydispatchfactory.h> |
|
33 |
|
34 |
|
35 #include "requestqueueoneshot.h" |
|
36 #include <ctsy/ltsy/ltsylogger.h> |
|
37 #include "mdispatchercallback.h" |
|
38 |
|
39 // FORWARD DECLARATIONS |
|
40 class CMmDataPackage; |
|
41 class MmMessageManagerCallback; |
|
42 class TDispatcherHolder; |
|
43 |
|
44 class MLtsyDispatchSupplementaryServicesSendNetworkServiceRequestNoFdnCheck; |
|
45 class MLtsyDispatchSupplementaryServicesGetCallWaitingStatus; |
|
46 class MLtsyDispatchSupplementaryServicesSendNetworkServiceRequest; |
|
47 class MLtsyDispatchSupplementaryServicesGetCallBarringStatus; |
|
48 class MLtsyDispatchSupplementaryServicesSetCallBarringStatus; |
|
49 class MLtsyDispatchSupplementaryServicesSetCallForwardingStatus; |
|
50 class MLtsyDispatchSupplementaryServicesSetCallWaitingStatus; |
|
51 class MLtsyDispatchSupplementaryServicesSetSsPassword; |
|
52 class MLtsyDispatchSupplementaryServicesGetCallForwardingStatus; |
|
53 class MLtsyDispatchSupplementaryServicesSendUssdMessage; |
|
54 class MLtsyDispatchSupplementaryServicesSendUssdMessageNoFdnCheck; |
|
55 class MLtsyDispatchSupplementaryServicesSendUssdRelease; |
|
56 class MLtsyDispatchSupplementaryServicesClearBlacklist; |
|
57 |
|
58 |
|
59 |
|
60 // CLASS DECLARATION |
|
61 |
|
62 /** |
|
63 * This class is responsible for packing and unpacking data belonging |
|
64 * to SupplementaryServices related requests to the Licensee LTSY. |
|
65 */ |
|
66 class CSupplementaryServicesDispatcher : public CBase, public MDispatcherCallback |
|
67 { |
|
68 public: |
|
69 |
|
70 virtual ~CSupplementaryServicesDispatcher(); |
|
71 |
|
72 static CSupplementaryServicesDispatcher* NewL( |
|
73 MLtsyDispatchFactoryV1& aLtsyFactory, |
|
74 MmMessageManagerCallback& aMessageManagerCallback, |
|
75 CRequestQueueOneShot& aRequestAsyncOneShot); |
|
76 |
|
77 static CSupplementaryServicesDispatcher* NewLC( |
|
78 MLtsyDispatchFactoryV1& aLtsyFactory, |
|
79 MmMessageManagerCallback& aMessageManagerCallback, |
|
80 CRequestQueueOneShot& aRequestAsyncOneShot); |
|
81 |
|
82 // Dispatcher functions for dispatching requests DOWN to the Licensee LTSY |
|
83 |
|
84 TInt DispatchSendNetworkServiceRequestNoFdnCheckL(const CMmDataPackage* aDataPackage); |
|
85 TInt DispatchGetCallWaitingStatusL(); |
|
86 TInt DispatchSendNetworkServiceRequestL(const CMmDataPackage* aDataPackage); |
|
87 TInt DispatchGetCallBarringStatusL(const CMmDataPackage* aDataPackage); |
|
88 TInt DispatchSetCallBarringStatusL(const CMmDataPackage* aDataPackage); |
|
89 TInt DispatchSetCallForwardingStatusL(const CMmDataPackage* aDataPackage); |
|
90 TInt DispatchSetCallWaitingStatusL(const CMmDataPackage* aDataPackage); |
|
91 TInt DispatchSetSsPasswordL(const CMmDataPackage* aDataPackage); |
|
92 TInt DispatchGetCallForwardingStatusL(const CMmDataPackage* aDataPackage); |
|
93 TInt DispatchSendUssdMessageL(const CMmDataPackage* aDataPackage); |
|
94 TInt DispatchSendUssdMessageNoFdnCheckL(const CMmDataPackage* aDataPackage); |
|
95 TInt DispatchSendUssdReleaseL(); |
|
96 TInt DispatchClearBlacklistL(); |
|
97 |
|
98 |
|
99 // Complete functions for receiving completions UP from the Licensee LTSY |
|
100 // via the CCtsyDispatcherCallback object. |
|
101 |
|
102 void CallbackNotifyCallBarringStatusChange(TInt aError, RMobilePhone::TMobilePhoneCBCondition aCondition); |
|
103 void CallbackReceiveUssdMessage(TInt aError, const TDesC8& aMessage, TUint8 aDcs, |
|
104 RMobileUssdMessaging::TMobileUssdMessageType aType, |
|
105 RMobileUssdMessaging::TMobileUssdDataFormat aFormat); |
|
106 void CallbackNotifyCallWaitingStatusChange(TInt aError, RMobilePhone::TMobileService aServiceGroup, RMobilePhone::TMobilePhoneCWStatus aStatus); |
|
107 void CallbackNotifyCallForwardingStatusChange(TInt aError, RMobilePhone::TMobilePhoneCFCondition aCallForwardingCondition); |
|
108 void CallbackNotifyCallForwardingActive(TInt aError, RMobilePhone::TMobileService aServiceGroup, RMobilePhone::TMobilePhoneCFActive aActiveType); |
|
109 void CallbackSendNetworkServiceRequestNoFdnCheck(TInt aError); |
|
110 void CallbackGetCallWaitingStatus(TInt aError, const CMobilePhoneCWList& aCallWaitingList); |
|
111 void CallbackSendNetworkServiceRequest(TInt aError); |
|
112 void CallbackGetCallBarringStatus(TInt aError, const CMobilePhoneCBList& aCallBarringList); |
|
113 void CallbackSetCallBarringStatus(TInt aError); |
|
114 void CallbackSetCallForwardingStatus(TInt aError); |
|
115 void CallbackSetCallWaitingStatus(TInt aError); |
|
116 void CallbackSetSsPassword(TInt aError); |
|
117 void CallbackGetCallForwardingStatus(TInt aError, const CMobilePhoneCFList& aCallForwardingList); |
|
118 void CallbackSendUssdMessage(TInt aError); |
|
119 void CallbackSendUssdMessageNoFdnCheck(TInt aError); |
|
120 void CallbackSendUssdRelease(TInt aError, TUint8 aOpCode, const TDesC& aAdditionalInfo); |
|
121 void CallbackClearBlacklist(TInt aError); |
|
122 void CallbackGetDiagnosticOctets(TInt aError, TInt aCallId, TUint8 aOctet); |
|
123 void CallbackNotifyAdditionalInfo(TInt aError, TUint8 aOperationCode, const TDesC8& aAdditionalInfo); |
|
124 void CallbackNotifyRequestComplete(TInt aError, TInt aStatus); |
|
125 void CallbackNotifyNetworkEventForwardMode(TInt aError, RMmCustomAPI::TSsType aType, RMmCustomAPI::TSsMode aMode, RMmCustomAPI::TSsForwMode aForwardMode); |
|
126 void CallbackNotifyNetworkEventCallWaiting(TInt aError, RMmCustomAPI::TSsMode aMode, TBool aCallIsWaiting); |
|
127 void CallbackNotifyNetworkEventHoldMode(TInt aError, RMmCustomAPI::TSsType aType, RMmCustomAPI::TSsMode aMode, RMmCustomAPI::TSsHoldMode aHoldMode); |
|
128 void CallbackNotifyNetworkEventConfrence(TInt aError, RMmCustomAPI::TSsType aType, RMmCustomAPI::TSsMode aMode, TBool aConferenceIndicator); |
|
129 void CallbackNotifyNetworkEventCug(TInt aError, RMmCustomAPI::TSsType aType, RMmCustomAPI::TSsMode aMode, TUint16 aCugIndex); |
|
130 void CallbackNotifyNetworkEventClirSuppression(TInt aError, RMmCustomAPI::TSsMode aMode, TBool aClirSuppressionRejected); |
|
131 void CallbackNotifyNetworkEventEctCallState(TInt aError, RMmCustomAPI::TSsType aType, RMmCustomAPI::TSsMode aMode, RMmCustomAPI::TSsEctState aEctCallState, RMmCustomAPI::TSsChoice aEctChoice, const TDesC& aRemotePartyNumber); |
|
132 void CallbackNotifyNetworkEvent(TInt aError, RMmCustomAPI::TSsType aType, RMmCustomAPI::TSsMode aMode); |
|
133 void CallbackNotifySendNetworkServiceRequest(TInt aError, RMobilePhone::TMobilePhoneNotifySendSSOperation aOperationCode, const TDesC& aAdditionalInfo); |
|
134 |
|
135 |
|
136 // From MDispatcherCallback |
|
137 void CallbackSync(CRequestQueueOneShot::TIpcDataPackage& aIpcDataPackage); |
|
138 |
|
139 // Other public functions |
|
140 void SetDispatcherHolder(TDispatcherHolder& aDispatcherHolder); |
|
141 |
|
142 private: |
|
143 |
|
144 CSupplementaryServicesDispatcher(MLtsyDispatchFactoryV1& aLtsyFactory, |
|
145 MmMessageManagerCallback& aMessageManagerCallback, |
|
146 CRequestQueueOneShot& aRequestAsyncOneShot); |
|
147 |
|
148 void ConstructL(); |
|
149 |
|
150 private: // Not owned |
|
151 |
|
152 MLtsyDispatchFactoryV1& iLtsyFactoryV1; |
|
153 MmMessageManagerCallback& iMessageManagerCallback; |
|
154 CRequestQueueOneShot& iRequestAsyncOneShot; |
|
155 TDispatcherHolder* iDispatcherHolder; |
|
156 |
|
157 // Interfaces in the Licensee LTSY, not owned by this object |
|
158 |
|
159 MLtsyDispatchSupplementaryServicesSendNetworkServiceRequestNoFdnCheck* iLtsyDispatchSupplementaryServicesSendNetworkServiceRequestNoFdnCheck; |
|
160 MLtsyDispatchSupplementaryServicesGetCallWaitingStatus* iLtsyDispatchSupplementaryServicesGetCallWaitingStatus; |
|
161 MLtsyDispatchSupplementaryServicesSendNetworkServiceRequest* iLtsyDispatchSupplementaryServicesSendNetworkServiceRequest; |
|
162 MLtsyDispatchSupplementaryServicesGetCallBarringStatus* iLtsyDispatchSupplementaryServicesGetCallBarringStatus; |
|
163 MLtsyDispatchSupplementaryServicesSetCallBarringStatus* iLtsyDispatchSupplementaryServicesSetCallBarringStatus; |
|
164 MLtsyDispatchSupplementaryServicesSetCallForwardingStatus* iLtsyDispatchSupplementaryServicesSetCallForwardingStatus; |
|
165 MLtsyDispatchSupplementaryServicesSetCallWaitingStatus* iLtsyDispatchSupplementaryServicesSetCallWaitingStatus; |
|
166 MLtsyDispatchSupplementaryServicesSetSsPassword* iLtsyDispatchSupplementaryServicesSetSsPassword; |
|
167 MLtsyDispatchSupplementaryServicesGetCallForwardingStatus* iLtsyDispatchSupplementaryServicesGetCallForwardingStatus; |
|
168 MLtsyDispatchSupplementaryServicesSendUssdMessage* iLtsyDispatchSupplementaryServicesSendUssdMessage; |
|
169 MLtsyDispatchSupplementaryServicesSendUssdMessageNoFdnCheck* iLtsyDispatchSupplementaryServicesSendUssdMessageNoFdnCheck; |
|
170 MLtsyDispatchSupplementaryServicesSendUssdRelease* iLtsyDispatchSupplementaryServicesSendUssdRelease; |
|
171 MLtsyDispatchSupplementaryServicesClearBlacklist* iLtsyDispatchSupplementaryServicesClearBlacklist; |
|
172 |
|
173 |
|
174 }; // class CSupplementaryServicesDispatcher |
|
175 |
|
176 #endif // __CSUPPLEMENTARYSERVICESDISPATCHER_H_ |
|
177 |