|
1 /** |
|
2 * Copyright (c) 2004-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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 /** |
|
21 @file |
|
22 @released |
|
23 */ |
|
24 |
|
25 #ifndef __T_BURCOMMON_H__ |
|
26 #define __T_BURCOMMON_H__ |
|
27 |
|
28 #include <connect/sbtypes.h> |
|
29 #include <s32file.h> |
|
30 |
|
31 using namespace conn; |
|
32 |
|
33 namespace bur_ts |
|
34 { |
|
35 |
|
36 // Directory names defining the Backup Archive naming scheme: |
|
37 _LIT(KRegFilesDir, "RegistrationData\\"); |
|
38 _LIT(KPassiveDataDir, "Passive\\"); |
|
39 _LIT(KActiveDataDir, "Active\\"); |
|
40 _LIT(KBaseDataDir, "Base\\"); |
|
41 _LIT(KIncrementalDataDir, "Incremental\\"); |
|
42 _LIT(KSnapshotDataDir, "Snapshot\\"); |
|
43 _LIT(KDataOwnerDir, "DataOwners\\"); |
|
44 |
|
45 _LIT(KData, "data"); |
|
46 _LIT(KSnapshot, "snapshot"); |
|
47 _LIT(KIncrement, "increment"); |
|
48 |
|
49 _LIT(KMidlet, "midlet"); |
|
50 |
|
51 _LIT(KSlash, "\\"); |
|
52 _LIT(KBackupExtn, ".bkp"); |
|
53 |
|
54 _LIT(KSidDir, "IdData\\"); |
|
55 |
|
56 // forward declaration |
|
57 class CBURTDataOwner; |
|
58 |
|
59 // Some usefull shorthands: |
|
60 typedef RPointerArray<CDataOwnerInfo> RDataOwnerArray; |
|
61 typedef RPointerArray<CSBSecureId> RSBSecureIdArray; |
|
62 |
|
63 typedef RPointerArray<CSBGenericTransferType> RTransferTypeArray; |
|
64 |
|
65 typedef RArray<CSBGenericDataType> RGenericDataTypeArray; |
|
66 |
|
67 // Indentation levels for logging: |
|
68 const TUint LOG_LEVEL1 = 1; |
|
69 const TUint LOG_LEVEL2 = 2; |
|
70 const TUint LOG_LEVEL3 = 3; |
|
71 const TUint LOG_LEVEL4 = 4; |
|
72 const TUint LOG_LEVEL5 = 5; |
|
73 const TUint LOG_LEVEL6 = 6; |
|
74 const TUint LOG_LEVEL7 = 7; |
|
75 const TUint LOG_LEVEL8 = 8; |
|
76 |
|
77 // Indentation marker for logging: |
|
78 _LIT(KIndentationMarker, "--"); |
|
79 |
|
80 enum TBackupMode |
|
81 /** |
|
82 @released |
|
83 @internalComponent |
|
84 */ |
|
85 { |
|
86 EBackupMode = 0, |
|
87 ERestoreMode = 1 |
|
88 }; |
|
89 |
|
90 enum TCurrentState |
|
91 /** |
|
92 @released |
|
93 @internalComponent |
|
94 */ |
|
95 { |
|
96 ERegistration =0, |
|
97 ESnapshots = 1, |
|
98 EBase = 2, |
|
99 EIncrements |
|
100 }; |
|
101 |
|
102 // ERROR MESSAGES: |
|
103 _LIT(KBURTestPanicText,"BURTestServer: "); |
|
104 |
|
105 // ERROR CODES: |
|
106 /** |
|
107 Panic A null pointer has been encountered |
|
108 @internalComponent |
|
109 */ |
|
110 const TInt KErrBURTestNullPointer = 1; |
|
111 |
|
112 /** |
|
113 Panic An invalid file name |
|
114 @internalComponent |
|
115 */ |
|
116 const TInt KErrBURTestInvalidFileName = 2; |
|
117 |
|
118 } |
|
119 |
|
120 #endif // __T_BURCOMMON_H__ |
|
121 |
|
122 |