1 /* |
|
2 * Copyright (c) 2005 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: Header file for CFotaServer |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef __FOTASERVER_H__ |
|
21 #define __FOTASERVER_H__ |
|
22 |
|
23 // INCLUDES |
|
24 #include <AknDoc.h> |
|
25 #include <aknapp.h> |
|
26 #include <AknServerApp.h> |
|
27 #include <coemain.h> |
|
28 #include <s32file.h> |
|
29 #include <DocumentHandler.h> |
|
30 #include <apmstd.h> |
|
31 #include <e32property.h> |
|
32 #include <SyncMLClient.h> |
|
33 #include <SyncMLClientDM.h> |
|
34 #include <hwrmpowerstatesdkpskeys.h> |
|
35 #include <SyncMLNotifier.h> |
|
36 #include <SyncMLNotifierParams.h> |
|
37 #include <SyncMLObservers.h> |
|
38 #include <fotastorage.h> |
|
39 #include <starterclient.h> |
|
40 |
|
41 #include "fotaserverPrivateCRKeys.h" |
|
42 |
|
43 #include "FotaIPCTypes.h" |
|
44 #include "FotaDB.h" |
|
45 #include "fotaConst.h" |
|
46 #include "fotadownload.h" |
|
47 #include "fotaupdate.h" |
|
48 #include "fmsclient.h" //The FMS Client header file |
|
49 |
|
50 |
|
51 //Forward declarations |
|
52 class CDevEncController; |
|
53 |
|
54 enum TOmaDmLrgObjDl |
|
55 { |
|
56 EOmaDmLrgObjDlFail = 1, |
|
57 EOmaDmLrgObjDlExec |
|
58 }; |
|
59 _LIT (KSWversionFile, "swv.txt"); |
|
60 /** Timeout to let cfotadownloader callstack to empty*/ |
|
61 const TInt KDownloadFinalizerWaitTime(1000000); |
|
62 |
|
63 /** Time interval between syncml session retry attempts*/ |
|
64 const TInt KSyncmlSessionRetryInterval(60000000); |
|
65 |
|
66 /** shutdown timer */ |
|
67 const TTimeIntervalMicroSeconds32 KFotaTimeShutDown(10000000); |
|
68 |
|
69 /** How many times generic alert sending should be tried in row. */ |
|
70 const TInt KSyncmlAttemptCount = 3; |
|
71 |
|
72 /** This P&S Key is used to notify DM UI on any download event. key=0 for idle and key=1 for download */ |
|
73 const TUint32 KFotaDownloadState = 0x00000001; |
|
74 |
|
75 /** If download is active this P&S key is set to ETrue, otherwise EFalse. |
|
76 * The key is owned by omadmappui**/ |
|
77 const TUint32 KFotaDownloadActive = 0x0000008; |
|
78 |
|
79 /** The P&S key to say DM UI to perform refresh of UI elements */ |
|
80 const TUint32 KFotaDMRefresh = 0x00000009; |
|
81 |
|
82 enum { |
|
83 ENo=0, |
|
84 EYes |
|
85 }; |
|
86 |
|
87 //Constants used when update happen NSC/DM |
|
88 enum { |
|
89 EFotaUpdateNSC=1, |
|
90 EFotaUpdateNSCBg, |
|
91 EFotaUpdateDM |
|
92 }; |
|
93 |
|
94 _LIT_SECURITY_POLICY_C1( KReadPolicy, ECapabilityReadDeviceData ); |
|
95 _LIT_SECURITY_POLICY_C1( KWritePolicy, ECapabilityWriteDeviceData ); |
|
96 |
|
97 //Constants for Device Encryption operation |
|
98 enum TDEOperations |
|
99 { |
|
100 EIdle = 0, |
|
101 EEncryption, |
|
102 EDecryption, |
|
103 EDecryptionPending |
|
104 }; |
|
105 // FORWARD CLASS DECLARATION |
|
106 |
|
107 class CFotaServer; |
|
108 class CFotaDownload; |
|
109 class CFotaUpdate; |
|
110 class CFotaSrvApp; |
|
111 class CFotaNetworkRegStatus; |
|
112 /** |
|
113 * Fota server. Handles client requests. Starts download and/or update. |
|
114 * |
|
115 * This class is |
|
116 * |
|
117 * @lib fotaserver |
|
118 * @since S60 v3.1 |
|
119 */ |
|
120 NONSHARABLE_CLASS( CFotaServer ) : public CAknAppServer, MSyncMLEventObserver |
|
121 { |
|
122 friend class CFotaSrvSession; |
|
123 friend class CFotaDownload; |
|
124 friend class CFotaUpdate; |
|
125 |
|
126 public: |
|
127 |
|
128 /** |
|
129 * C++ default constructor. |
|
130 */ |
|
131 CFotaServer(); |
|
132 |
|
133 /** |
|
134 * Destructor. |
|
135 */ |
|
136 virtual ~CFotaServer(); |
|
137 |
|
138 public: // New functions |
|
139 |
|
140 |
|
141 /** |
|
142 * Create database |
|
143 * |
|
144 * @since S60 v3.1 |
|
145 * @param aLargObj Is it largeobject download (or dlmgr download) |
|
146 * @param aPkgId Packageid of the download |
|
147 * @return none |
|
148 */ |
|
149 void UpdatePackageDownloadCompleteL( TBool aLargObj,const TInt aPkgId); |
|
150 |
|
151 |
|
152 /** |
|
153 * Check s/w version with the current version |
|
154 * |
|
155 * @since S60 v3.2 |
|
156 * @param none |
|
157 * @return Bool value(matches or not) |
|
158 */ |
|
159 TBool CheckSWVersionL(); |
|
160 |
|
161 /** |
|
162 * Start download |
|
163 * |
|
164 * @since S60 v3.1 |
|
165 * @param aParams Package state params to be save in db |
|
166 * @param aPkgURL URL |
|
167 * @return none |
|
168 */ |
|
169 void DownloadL(TDownloadIPCParams aParams,const TDesC8& aPkgURL); |
|
170 |
|
171 |
|
172 /** |
|
173 * Start download which finishes with update |
|
174 * |
|
175 * @since S60 v3.1 |
|
176 * @param aParams Package state params to be save in db |
|
177 * @param aPkgURL URL |
|
178 * @return none |
|
179 */ |
|
180 void DownloadAndUpdateL(TDownloadIPCParams aParams |
|
181 ,const TDesC8& aPkgURL); |
|
182 |
|
183 |
|
184 |
|
185 /** |
|
186 * Start update |
|
187 * |
|
188 * @since S60 v3.1 |
|
189 * @param aParams Package state params to be save in db |
|
190 * @return none |
|
191 */ |
|
192 void UpdateL( const TDownloadIPCParams& aParams ); |
|
193 |
|
194 |
|
195 |
|
196 /** |
|
197 * Update, triggered by scheduler |
|
198 * |
|
199 * @since S60 v3.1 |
|
200 * @param aUpdate Update details |
|
201 * @return none |
|
202 */ |
|
203 void ScheduledUpdateL( TFotaScheduledUpdate aUpdate ); |
|
204 |
|
205 /** |
|
206 * Delete swupd package |
|
207 * |
|
208 * @since S60 v3.1 |
|
209 * @param aPkgId Package id |
|
210 * @return none |
|
211 */ |
|
212 void DeletePackageL ( const TInt aPkgId); |
|
213 |
|
214 |
|
215 |
|
216 /** |
|
217 * Get state of a swupd package |
|
218 * |
|
219 * @since S60 v3.1 |
|
220 * @param aPkgId Package id |
|
221 * @return Package state |
|
222 */ |
|
223 TPackageState GetStateL( const TInt aPkgId); |
|
224 |
|
225 |
|
226 /** |
|
227 * Open a store to save swupd into |
|
228 * |
|
229 * @since S60 v3.1 |
|
230 * @param aMessage containing client side chunk handle |
|
231 * @return None |
|
232 */ |
|
233 void OpenUpdatePackageStoreL ( const RMessage2& aMessage ); |
|
234 |
|
235 /** |
|
236 * Gets the downloaded and complete size of the update package |
|
237 * |
|
238 * @since S60 v3.2 |
|
239 * @param aPkgId Package id |
|
240 * @param aDownloadedSize size of download package in bytes |
|
241 * @param aTotalSize size of the complete package in bytes |
|
242 * @return None |
|
243 */ |
|
244 void GetDownloadUpdatePackageSizeL (const TInt aPkgId, TInt& aDownloadedSize, TInt& aTotalSize); |
|
245 |
|
246 /** |
|
247 * Tries to resume the download. |
|
248 * |
|
249 * @since S60 v3.2 |
|
250 * @param aQueryUser Whether to query user for resume? |
|
251 * @return None |
|
252 */ |
|
253 void TryResumeDownloadL(TBool aQueryUser); |
|
254 |
|
255 /** |
|
256 * Invoke Fota Monitory Service when the download gets suspended |
|
257 * |
|
258 * @since S60 v3.2 |
|
259 * @return None |
|
260 */ |
|
261 void InvokeFmsL(); |
|
262 |
|
263 /** |
|
264 * Cancels any outstanding request for resume notification |
|
265 * |
|
266 * @since S60 v3.2 |
|
267 * @return None |
|
268 */ |
|
269 void CancelFmsL(); |
|
270 |
|
271 /** |
|
272 * Sets the phone's startup reason. This is used by Fota Startup Pluggin to any decision. |
|
273 * |
|
274 * @since S60 v3.2 |
|
275 * @param aReason Startup reason, either download interrupted |
|
276 * @return None |
|
277 */ |
|
278 void SetStartupReason(TInt aReason); |
|
279 |
|
280 /** |
|
281 * Shutdown DM UI application |
|
282 * @since S60 v3.2 |
|
283 * @return None |
|
284 */ |
|
285 void ShutApp(); |
|
286 |
|
287 /** |
|
288 * Stops ongoing download, if any. |
|
289 * @since S60 v3.2 |
|
290 * @param aReason Reason for stopping the download. |
|
291 * @return None |
|
292 */ |
|
293 void StopDownload(TInt aReason); |
|
294 |
|
295 /** |
|
296 * Read data from chunk |
|
297 * |
|
298 * @since S60 v3.1 |
|
299 * @param aSize Size of data |
|
300 * @param aError error caught while writing data into FS |
|
301 * @return none |
|
302 */ |
|
303 void ReadChunkL ( const TInt aSize ,TInt aError ); |
|
304 |
|
305 |
|
306 /** |
|
307 * Check if swupd package fits into store |
|
308 * |
|
309 * @since S60 v3.1 |
|
310 * @param aSize Size of swupd |
|
311 * @return Does it fit? |
|
312 */ |
|
313 TBool IsPackageStoreSizeAvailableL ( const TInt aSize ); |
|
314 |
|
315 |
|
316 /** |
|
317 * Get ids of present swupd packages |
|
318 * |
|
319 * @since S60 v3.1 |
|
320 * @param aPackageIdList On return, ids will be here |
|
321 * @return None |
|
322 */ |
|
323 void GetUpdatePackageIdsL(TDes16& aPackageIdList); |
|
324 |
|
325 |
|
326 /** |
|
327 * Get time of last update |
|
328 * |
|
329 * @since S60 v3.1 |
|
330 * @param aTime On return, time of last update |
|
331 * @return None |
|
332 */ |
|
333 void GetUpdateTimeStampL (TDes16& aTime) ; |
|
334 |
|
335 |
|
336 /** |
|
337 * Set download to be finalized. |
|
338 * |
|
339 * @since S60 v3.1 |
|
340 * @param aDLState Final state of the download |
|
341 * @return None |
|
342 */ |
|
343 void FinalizeDownloadL( const TPackageState& aDLState ); |
|
344 |
|
345 |
|
346 /** |
|
347 * Set update to be finalized. |
|
348 * |
|
349 * @since S60 v3.1 |
|
350 * @param None |
|
351 * @return None |
|
352 */ |
|
353 void FinalizeUpdateL(); |
|
354 |
|
355 /** |
|
356 * Monitors for the battery in case of USB charger |
|
357 * |
|
358 * @since S60 v3.2.3 |
|
359 * @param aLevel - level of the battery charge to monitor |
|
360 * @return None |
|
361 */ |
|
362 void MonitorBattery(TInt aLevel); |
|
363 |
|
364 /** |
|
365 * Finalize download |
|
366 * |
|
367 * @since S60 v3.1 |
|
368 * @param None |
|
369 * @return None |
|
370 */ |
|
371 void DoFinalizeDownloadL(); |
|
372 |
|
373 |
|
374 /** |
|
375 * Finalize Update |
|
376 * |
|
377 * @since S60 v3.1 |
|
378 * @param None |
|
379 * @return None |
|
380 */ |
|
381 void DoFinalizeUpdateL(); |
|
382 |
|
383 |
|
384 /** |
|
385 * Read update result file and report result back to DM server |
|
386 * |
|
387 * @since S60 v3.1 |
|
388 * @param None |
|
389 * @return None |
|
390 */ |
|
391 void DoExecuteResultFileL(); |
|
392 |
|
393 /** |
|
394 * Deletes the update result file |
|
395 * |
|
396 * @since S60 v3.2 |
|
397 * @param None |
|
398 * @return None |
|
399 */ |
|
400 void DoDeleteUpdateResultFileL(); |
|
401 |
|
402 /** |
|
403 * Close syncml session |
|
404 * |
|
405 * @since S60 v3.1 |
|
406 * @param none |
|
407 * @return none |
|
408 */ |
|
409 void DoCloseSMLSessionL(); |
|
410 |
|
411 /** |
|
412 * Shutdown fotaserver, if there's no operations in progress ( |
|
413 * download,update) |
|
414 * |
|
415 * @since S60 v3.1 |
|
416 * @param None |
|
417 * @return Error |
|
418 */ |
|
419 TInt TryToShutDownFotaServer(); |
|
420 |
|
421 |
|
422 /** |
|
423 * Get reference to storageplugin. Load it, if not existing |
|
424 * |
|
425 * @since S60 v3.1 |
|
426 * @param None |
|
427 * @return Reference to storage |
|
428 */ |
|
429 CFotaStorage* StoragePluginL(); |
|
430 |
|
431 |
|
432 /** |
|
433 * Do cleanup for package |
|
434 * |
|
435 * @since S60 v3.1 |
|
436 * @param aPackageID Packageid |
|
437 * @return None |
|
438 */ |
|
439 void GenericAlertSentL( const TInt aPackageID ); |
|
440 |
|
441 |
|
442 /** |
|
443 * Create DM session to DM server (identified by profileid) |
|
444 * |
|
445 * @since S60 v3.1 |
|
446 * @param aProfileId DM profile id |
|
447 * @param aIapid IAP id. If not kerrnone, will be used instead |
|
448 * of profiles' IAP id. |
|
449 * @return none |
|
450 */ |
|
451 void CreateDeviceManagementSessionL( TPackageState& aState ); |
|
452 |
|
453 |
|
454 /** |
|
455 * Get profiles' data. |
|
456 * |
|
457 * @since S60 v3.1 |
|
458 * @param aSyncml syncml session. must be open. |
|
459 * @param aProf profile id. |
|
460 * @param aIapid iapid |
|
461 * @param aSrvAA server alerted action |
|
462 * @param aUIJob is current dm job started from ui |
|
463 * @param aSanVal the SAN bit set by server for the DM Session |
|
464 * @return none |
|
465 */ |
|
466 void GetProfileDataL( RSyncMLSession* aSyncml,const TSmlProfileId aProf |
|
467 , TInt& aIapId, TSmlServerAlertedAction& aSrvAA,TBool& aUIJob, TInt& aSanVal); |
|
468 |
|
469 /** |
|
470 * Gets the EikonEnv object |
|
471 * |
|
472 * @since S60 v3.1 |
|
473 * @param None |
|
474 * @return CEikonEnv |
|
475 */ |
|
476 CEikonEnv* GetEikEnv(); |
|
477 |
|
478 |
|
479 /** |
|
480 * Callback function to notify the network status |
|
481 * |
|
482 * @since S60 v3.2 |
|
483 * @param Status of network connection |
|
484 * @return None |
|
485 */ |
|
486 void ReportNetworkStatus(TBool status); |
|
487 |
|
488 |
|
489 |
|
490 /** |
|
491 * Get the software version of the device |
|
492 * @since S60 v3.2 |
|
493 * @param s/w version |
|
494 * @return error |
|
495 */ |
|
496 TInt GetSoftwareVersion(TDes& aVersion); |
|
497 |
|
498 /** |
|
499 * Incase of large object download failure |
|
500 * Updates the fota database state & reason information |
|
501 * @since S60 v3.2 |
|
502 * @param None |
|
503 * @return None |
|
504 */ |
|
505 void UpdateDBdataL(); |
|
506 |
|
507 /** |
|
508 * stores the client id who triggered the update |
|
509 * @since S60 v3.2 |
|
510 * @param aClient, client Id |
|
511 * @return None |
|
512 */ |
|
513 void SetInstallUpdateClientL(TInt aClient); |
|
514 |
|
515 /** |
|
516 * returns the client id,who triggered the update |
|
517 * @since S60 v3.2 |
|
518 * @param None |
|
519 * @return TInt |
|
520 */ |
|
521 TInt GetInstallUpdateClientL(); |
|
522 |
|
523 |
|
524 /** |
|
525 * Checks for IAP Id exists or not in commsdb |
|
526 * IAPId used for resuming the paused download |
|
527 * @since S60 v5.0 |
|
528 * @param IapId |
|
529 * @return ETrue/EFalse |
|
530 */ |
|
531 TBool CheckIapExistsL(TUint32 aIapId); |
|
532 |
|
533 /** |
|
534 * This method is called to check if dencryption needs to be performed. |
|
535 */ |
|
536 TBool NeedToDecryptL(const TInt &aPkgId, TDriveNumber &aDrive); |
|
537 |
|
538 /** |
|
539 * This method is called to start the decryption operation. |
|
540 */ |
|
541 void DoStartDecryptionL(); |
|
542 |
|
543 /** |
|
544 * This method is called once the decryption operation is complete. |
|
545 */ |
|
546 void HandleDecryptionCompleteL(TInt aResult, TInt aValue = 0); |
|
547 |
|
548 /** |
|
549 * This method is called to check if encryption needs to be performed. |
|
550 */ |
|
551 TBool NeedToEncryptL(TDriveNumber &aDrive); |
|
552 |
|
553 /** |
|
554 * This method is called to start the encryption operation. |
|
555 */ |
|
556 void DoStartEncryptionL(); |
|
557 |
|
558 /** |
|
559 * This method is called once the encryption operation is complete. |
|
560 */ |
|
561 void HandleEncryptionCompleteL(TInt aResult, TInt aValue = 0); |
|
562 |
|
563 /** |
|
564 * Gets the device encryption operation |
|
565 */ |
|
566 TInt GetDEOperation(); |
|
567 |
|
568 |
|
569 /** |
|
570 * Is server initialized? Must be public for session to use. |
|
571 */ |
|
572 TBool iInitialized; |
|
573 |
|
574 /** |
|
575 * Whether Fota server should close or not |
|
576 */ |
|
577 TBool iNeedToClose; |
|
578 |
|
579 /** |
|
580 * handles notifier completion |
|
581 */ |
|
582 CFotaDownloadNotifHandler* iNotifHandler; |
|
583 |
|
584 public: // from base classes |
|
585 |
|
586 /** |
|
587 * Creator |
|
588 * Not own |
|
589 */ |
|
590 CFotaSrvApp* iParentApp; |
|
591 |
|
592 /** |
|
593 * CreateServiceL. Creates session. |
|
594 * @param aServiceType |
|
595 * @return CApaAppServiceBase* |
|
596 */ |
|
597 CApaAppServiceBase* CreateServiceL( TUid aServiceType ) const; |
|
598 /** |
|
599 * Handle syncml event |
|
600 * @param aEvent |
|
601 * @param aIdentifier |
|
602 * @param aError |
|
603 * @param aAdditionalData |
|
604 * @return none |
|
605 */ |
|
606 void OnSyncMLSessionEvent(TEvent aEvent, TInt aIdentifier, TInt aError, TInt aAdditionalData) ; |
|
607 |
|
608 /** |
|
609 * Reference to client side chunk. Swupd comes this way. |
|
610 */ |
|
611 RChunk iChunk; |
|
612 |
|
613 |
|
614 /** |
|
615 * Used for package state saving. |
|
616 */ |
|
617 CFotaDB* iDatabase; |
|
618 |
|
619 |
|
620 /** |
|
621 * Used for downloading. |
|
622 */ |
|
623 CFotaDownload* iDownloader; |
|
624 |
|
625 |
|
626 /** |
|
627 * Used for starting update of fw. |
|
628 */ |
|
629 CFotaUpdate* iUpdater; |
|
630 |
|
631 |
|
632 /** |
|
633 * Used for deleting download. |
|
634 */ |
|
635 CPeriodic* iDownloadFinalizer; |
|
636 |
|
637 |
|
638 /** |
|
639 * Used for deleting update. |
|
640 */ |
|
641 CPeriodic* iUpdateFinalizer; |
|
642 |
|
643 |
|
644 /** |
|
645 * Used for reading result file. |
|
646 */ |
|
647 CPeriodic* iTimedExecuteResultFile; |
|
648 |
|
649 |
|
650 /** |
|
651 * Used for closing syncml session |
|
652 */ |
|
653 CPeriodic* iTimedSMLSessionClose; |
|
654 |
|
655 /** |
|
656 * ConstructL |
|
657 * |
|
658 * @since S60 v3.1 |
|
659 * @param aFixedServerName Name of this app server |
|
660 * @return none |
|
661 */ |
|
662 virtual void ConstructL(const TDesC &aFixedServerName); |
|
663 |
|
664 protected: // from base classes |
|
665 |
|
666 |
|
667 /** |
|
668 * DoConnect. |
|
669 * |
|
670 * @since S60 v3.1 |
|
671 * @param aMessage IPC message |
|
672 * @return none |
|
673 */ |
|
674 void DoConnect(const RMessage2& aMessage); |
|
675 |
|
676 |
|
677 /** |
|
678 * When last client disconnects, this is called. |
|
679 * |
|
680 * @since S60 v3.1 |
|
681 * @param none |
|
682 * @return none |
|
683 */ |
|
684 void HandleAllClientsClosed(); |
|
685 |
|
686 |
|
687 private: // new functions |
|
688 |
|
689 |
|
690 /** |
|
691 * Latter part of constructing. It's ensured that parent fotaserver is |
|
692 * constructed only once, and child fotaserver is not constructed at all. |
|
693 * Client fotaserver has a task of saving swupd as its only task. It should |
|
694 * not update swupd states. |
|
695 * |
|
696 * @since S60 v3.1 |
|
697 * @param aMessage Client process details |
|
698 * @return none |
|
699 */ |
|
700 void ClientAwareConstructL( const RMessage2 &aMessage ); |
|
701 |
|
702 |
|
703 /** |
|
704 * Loads storage plugin if not loaded. |
|
705 * |
|
706 * @since S60 v3.1 |
|
707 * @param none |
|
708 * @return none |
|
709 */ |
|
710 void LoadStoragePluginL (); |
|
711 |
|
712 |
|
713 /** |
|
714 * Unloads storage plugin. |
|
715 * |
|
716 * @since S60 v3.1 |
|
717 * @param none |
|
718 * @return none |
|
719 */ |
|
720 void UnLoadStoragePluginL (); |
|
721 |
|
722 |
|
723 |
|
724 /** |
|
725 * Resets the fota state |
|
726 * @since S60 v3.2 |
|
727 * @param IPC params |
|
728 * @return None |
|
729 */ |
|
730 |
|
731 void ResetFotaStateL(const TDownloadIPCParams& aParams); |
|
732 |
|
733 /** |
|
734 * Starts network monitoring operaiton for defined interval and retries |
|
735 * |
|
736 * @since S60 v3.2 |
|
737 * @param None |
|
738 * @return None |
|
739 */ |
|
740 void StartNetworkMonitorL(); |
|
741 |
|
742 |
|
743 private: // Data |
|
744 |
|
745 |
|
746 /** |
|
747 * The state that iDownloader was in, when it called to be finalized. |
|
748 */ |
|
749 TPackageState iDLFinalizeState; |
|
750 |
|
751 /** |
|
752 * The state before sending generic alert. |
|
753 */ |
|
754 TPackageState iStoredState; |
|
755 |
|
756 |
|
757 /** |
|
758 * Storage class (plugin). |
|
759 */ |
|
760 CFotaStorage* iStorage; |
|
761 |
|
762 |
|
763 /** |
|
764 * Packageid of the swupd being stored. Used only by child fotaserver. |
|
765 */ |
|
766 TInt iStorageDownloadPackageId; |
|
767 |
|
768 |
|
769 /** |
|
770 * Destructor key of the storage plugin. |
|
771 */ |
|
772 TUid iStorageDtorKey; |
|
773 |
|
774 |
|
775 /** |
|
776 * Destructor key of the storage plugin. |
|
777 */ |
|
778 RWriteStream* iStorageStream; |
|
779 |
|
780 |
|
781 /** |
|
782 * File server session |
|
783 */ |
|
784 RFs iFs; |
|
785 |
|
786 |
|
787 /** |
|
788 * Tries to periodically shut down fotaserver |
|
789 */ |
|
790 CPeriodic* iAppShutter; |
|
791 |
|
792 /** |
|
793 * Syncmlsession for creating dmsession |
|
794 */ |
|
795 RSyncMLSession iSyncMLSession; |
|
796 |
|
797 /** |
|
798 * Class that checks for network availability |
|
799 * |
|
800 */ |
|
801 CFotaNetworkRegStatus* iMonitor; |
|
802 |
|
803 /** |
|
804 * How many times to try dm session |
|
805 */ |
|
806 TInt iSyncMLAttempts; |
|
807 |
|
808 /** |
|
809 * sync job id |
|
810 */ |
|
811 TSmlJobId iSyncJobId; |
|
812 |
|
813 /** |
|
814 * profile |
|
815 */ |
|
816 TSmlProfileId iSyncProfile; |
|
817 |
|
818 /** |
|
819 * Reference to eikonenv. Used by other classes |
|
820 * |
|
821 */ |
|
822 CEikonEnv* iEikEnv; |
|
823 |
|
824 /** |
|
825 * To tell whether Generic Alert sending is being retried or not. This is checked before shutting down fota server |
|
826 * |
|
827 */ |
|
828 TBool iRetryingGASend; |
|
829 |
|
830 /** |
|
831 * To tell whether network is available to send Generic Alert. |
|
832 * |
|
833 */ |
|
834 TBool iNetworkAvailable; |
|
835 |
|
836 /** |
|
837 * The Fota Monitory Client object |
|
838 */ |
|
839 RFMSClient iFMSClient; |
|
840 |
|
841 /** |
|
842 * For sending GA, this will set to fotastate's iapid |
|
843 */ |
|
844 TInt iIapId; |
|
845 /** |
|
846 * Tells the session mode. |
|
847 */ |
|
848 TInt iSessMode; |
|
849 |
|
850 /** |
|
851 * Tells about who started resume. |
|
852 */ |
|
853 TInt iUserResume; |
|
854 |
|
855 /** |
|
856 * Tells which client triggered install update. |
|
857 */ |
|
858 TInt iInstallupdClient; |
|
859 |
|
860 /** |
|
861 * The pointer to encryption controller |
|
862 */ |
|
863 CDevEncController *iDEController; |
|
864 |
|
865 /** |
|
866 * Holds the storage drive of the package. |
|
867 */ |
|
868 TDriveNumber iStorageDrive; |
|
869 |
|
870 }; |
|
871 |
|
872 #endif |
|
873 |
|
874 // End of File |
|