1 /* |
|
2 * Copyright (c) 2008 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 of CIAUpdateFirstTimeDateFile class |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 #ifndef IA_UPDATE_FIRSTTIMEDATE_FILE_H |
|
24 #define IA_UPDATE_FIRSTTIMEDATE_FILE_H |
|
25 |
|
26 #include <e32std.h> |
|
27 #include <s32strm.h> |
|
28 #include <e32cmn.h> |
|
29 #include <f32file.h> |
|
30 #include <e32const.h> |
|
31 |
|
32 |
|
33 /** |
|
34 * |
|
35 */ |
|
36 class CIAUpdateFirstTimeDateFile : public CBase |
|
37 { |
|
38 |
|
39 public: |
|
40 |
|
41 static CIAUpdateFirstTimeDateFile* NewL( const TDesC& aFile ); |
|
42 |
|
43 static CIAUpdateFirstTimeDateFile* NewLC( const TDesC& aFile ); |
|
44 |
|
45 |
|
46 ~CIAUpdateFirstTimeDateFile(); |
|
47 |
|
48 |
|
49 TBool ReadDataL(); |
|
50 |
|
51 void WriteDataL(); |
|
52 |
|
53 const TTime& FirstTime() const; |
|
54 |
|
55 void SetCurrentFirstTime(); |
|
56 |
|
57 |
|
58 private: |
|
59 |
|
60 // Prevent these if not implemented |
|
61 CIAUpdateFirstTimeDateFile( const CIAUpdateFirstTimeDateFile& aObject ); |
|
62 CIAUpdateFirstTimeDateFile& operator =( const CIAUpdateFirstTimeDateFile& aObject ); |
|
63 |
|
64 |
|
65 CIAUpdateFirstTimeDateFile(); |
|
66 |
|
67 virtual void ConstructL( const TDesC& aFile ); |
|
68 |
|
69 |
|
70 void InternalizeL( RReadStream& aStream ); |
|
71 |
|
72 void ExternalizeL( RWriteStream& aStream ); |
|
73 |
|
74 |
|
75 private: // data |
|
76 |
|
77 // file server session |
|
78 RFs iFsSession; |
|
79 |
|
80 // file path |
|
81 TFileName iPath; |
|
82 |
|
83 |
|
84 // Time when IAD started first time |
|
85 TTime iFirstTime; |
|
86 |
|
87 }; |
|
88 |
|
89 #endif // IA_UPDATE_FIRSTTIMEDATE_FILE_H |
|
90 |
|