1 /* |
|
2 * Copyright (c) 2007-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: account creation plugin params header file |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef ACPBROWSERPARAMS_H |
|
20 #define ACPBROWSERPARAMS_H |
|
21 |
|
22 #include <e32base.h> |
|
23 #include <etelmm.h> |
|
24 |
|
25 #ifdef __PLUG_AND_PLAY_MOBILE_SERVICES |
|
26 #include <PnpUtilImpl.h> |
|
27 #else |
|
28 /* |
|
29 * temporary defines, remove when PNP is stuff available |
|
30 */ |
|
31 |
|
32 const TInt KMaxVersionStringLength(32); |
|
33 const TInt KNonceLength(8); |
|
34 const TInt KMaxKeyInfoLength(20); |
|
35 _LIT( KPnpUtilDllFileName, "Pnp.dll" ); |
|
36 const TUid KPnpUtilDllUid = { 0x1020433A }; |
|
37 |
|
38 class CPnpUtilImpl; |
|
39 #endif |
|
40 |
|
41 #include <wlaninternalpskeys.h> |
|
42 #include <sysversioninfo.h> |
|
43 |
|
44 #include "accountcreationengineconstants.h" |
|
45 |
|
46 |
|
47 /* |
|
48 * CACPBrowserParams |
|
49 * Encapsulates parameters needed for the Activation Server link |
|
50 */ |
|
51 class CACPBrowserParams : public CBase |
|
52 { |
|
53 public: |
|
54 |
|
55 static CACPBrowserParams* NewL(); |
|
56 static CACPBrowserParams* NewLC(); |
|
57 |
|
58 /** |
|
59 * Destructor. |
|
60 */ |
|
61 virtual ~CACPBrowserParams(); |
|
62 |
|
63 /** |
|
64 * Gets parameters, i.e. appends parameters to given URL. |
|
65 * |
|
66 * @since S60 v3.2 |
|
67 * @param aUrl URL in which parameters are appended. |
|
68 */ |
|
69 void GetParameters( TDes& aUrl ); |
|
70 |
|
71 private: |
|
72 |
|
73 CACPBrowserParams(); |
|
74 void ConstructL( ); |
|
75 |
|
76 /** |
|
77 * Retrieves parameters for the Service Activation link. |
|
78 * |
|
79 * @since S60 v3.2 |
|
80 */ |
|
81 void RetrieveParamsL(); |
|
82 |
|
83 /** |
|
84 * Gets phone model and stores it to iPhoneModel. |
|
85 * |
|
86 * @since S60 v3.2 |
|
87 */ |
|
88 void RetrievePhoneModel(); |
|
89 |
|
90 /** |
|
91 * Retrieves info on home network (incl. MCC, MNC). |
|
92 * |
|
93 * @since S60 v3.2 |
|
94 */ |
|
95 void RetrieveHomeNetworkInfoL(); |
|
96 |
|
97 /** |
|
98 * Retrieves Key info and creates nonce for signing |
|
99 * (PnpProvisioning client). |
|
100 * |
|
101 * @since S60 v3.2 |
|
102 */ |
|
103 void RetrieveSigningParamsL(); |
|
104 |
|
105 /** |
|
106 * Retrieves WLAN MAC address. |
|
107 * |
|
108 * @since S60 v3.2 |
|
109 */ |
|
110 void RetrieveWlanMacAddress(); |
|
111 |
|
112 /** |
|
113 * Retrieves phone serial number (IMEI) and variant code. |
|
114 * |
|
115 * @since S60 v3.2 |
|
116 */ |
|
117 void RetrievePhoneInfoL(); |
|
118 |
|
119 /** |
|
120 * Checks if the phone has network or is searching for one. |
|
121 * |
|
122 * @since S60 v3.2 |
|
123 * @return ETrue is network available, EFalse if no network available. |
|
124 */ |
|
125 TBool RegisteredInNetwork(); |
|
126 |
|
127 private: |
|
128 |
|
129 /** |
|
130 * Telephony Server (etelmm). |
|
131 */ |
|
132 RTelServer iTelServer; |
|
133 |
|
134 /** |
|
135 * Phone Object |
|
136 */ |
|
137 RMobilePhone iPhone; |
|
138 |
|
139 /** |
|
140 * Phone model. |
|
141 */ |
|
142 TBuf<RMobilePhone::KPhoneModelIdSize> iPhoneModel; |
|
143 |
|
144 /** |
|
145 * Home MCC. |
|
146 */ |
|
147 TBuf<KMaxMCC> iHomeMcc; |
|
148 |
|
149 /** |
|
150 * Home MNC. |
|
151 */ |
|
152 TBuf<KMaxMNC> iHomeMnc; |
|
153 |
|
154 /** |
|
155 * Key information. |
|
156 */ |
|
157 TBuf8<KMaxKeyInfoLength> iKeyInfo; |
|
158 |
|
159 /** |
|
160 * Nonce. |
|
161 */ |
|
162 TBuf8<KNonceLength> iNonce; |
|
163 |
|
164 /** |
|
165 * WLAN MAC address. |
|
166 */ |
|
167 TBuf<KPSWlanMacAddressLength*3> iWlanMACAddress; |
|
168 |
|
169 /** |
|
170 * IMEI. |
|
171 */ |
|
172 TBuf<RMobilePhone::KPhoneSerialNumberSize> iImei; |
|
173 |
|
174 /** |
|
175 * Variant code. |
|
176 */ |
|
177 TBuf<KSysVersionInfoTextLength> iVariant; |
|
178 |
|
179 /** |
|
180 * PnP utility class instance used in retrieving parameters. |
|
181 */ |
|
182 CPnpUtilImpl* iPnpUtil; |
|
183 |
|
184 }; |
|
185 |
|
186 #endif // ACPBROWSERPARAMS_H |
|
187 |
|
188 // End of file. |
|