sl@0
|
1 |
// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
2 |
// All rights reserved.
|
sl@0
|
3 |
// This component and the accompanying materials are made available
|
sl@0
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
sl@0
|
5 |
// which accompanies this distribution, and is available
|
sl@0
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
7 |
//
|
sl@0
|
8 |
// Initial Contributors:
|
sl@0
|
9 |
// Nokia Corporation - initial contribution.
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// Contributors:
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Description:
|
sl@0
|
14 |
// t_dbplatsecdef - Common declarations
|
sl@0
|
15 |
//
|
sl@0
|
16 |
//
|
sl@0
|
17 |
|
sl@0
|
18 |
#ifndef T_DBPLATSECDEF_H
|
sl@0
|
19 |
#define T_DBPLATSECDEF_H
|
sl@0
|
20 |
|
sl@0
|
21 |
#include <e32test.h>
|
sl@0
|
22 |
#include <d32dbms.h>
|
sl@0
|
23 |
|
sl@0
|
24 |
#ifdef __T_DBPLATSECDEF__
|
sl@0
|
25 |
#define CONST_LIT8(var, val) extern const TLitC8<sizeof(val)> var = {sizeof(val) - 1, val}
|
sl@0
|
26 |
#define CONST_LIT16(var, val) extern const TLitC16<sizeof(L##val)/2> var = {sizeof(L##val)/2 - 1, L##val}
|
sl@0
|
27 |
#define CONST_TTEXT(var, val) extern const TText var = val
|
sl@0
|
28 |
#else
|
sl@0
|
29 |
#define CONST_LIT8(var, val) extern const TLitC8<sizeof(val)> var
|
sl@0
|
30 |
#define CONST_LIT16(var, val) extern const TLitC16<sizeof(L##val)/2> var
|
sl@0
|
31 |
#define CONST_TTEXT(var, val) extern const TText var
|
sl@0
|
32 |
#endif
|
sl@0
|
33 |
|
sl@0
|
34 |
#ifdef _UNICODE
|
sl@0
|
35 |
#define CONST_LIT(var, val) CONST_LIT16(var, val)
|
sl@0
|
36 |
#else
|
sl@0
|
37 |
#define CONST_LIT(var, val) CONST_LIT8(var, val)
|
sl@0
|
38 |
#endif
|
sl@0
|
39 |
|
sl@0
|
40 |
extern RTest TheTest;
|
sl@0
|
41 |
extern RDbs TheDbs;
|
sl@0
|
42 |
extern RDbNamedDatabase TheDb1;
|
sl@0
|
43 |
extern RDbNamedDatabase TheDb2;
|
sl@0
|
44 |
extern RDbTable TheTbl1;
|
sl@0
|
45 |
extern RDbTable TheTbl2;
|
sl@0
|
46 |
|
sl@0
|
47 |
const TUid KSecureDbUid = {0x11335577};
|
sl@0
|
48 |
const TUid KSecureDbUid2 = {0x11335578};//Not enough rights for database operations here
|
sl@0
|
49 |
|
sl@0
|
50 |
const TInt KDatabaseNamePos = 2;
|
sl@0
|
51 |
|
sl@0
|
52 |
CONST_LIT(KSecure, "SECURE");
|
sl@0
|
53 |
CONST_LIT(KDb1Name, "c:A.dB");
|
sl@0
|
54 |
CONST_LIT(KDb2Name, "C:b.Db");
|
sl@0
|
55 |
CONST_LIT(KDb3Name, "c:C.db");
|
sl@0
|
56 |
CONST_LIT(KTableName1, "ATBL");
|
sl@0
|
57 |
CONST_LIT(KTableName2, "BTbL");
|
sl@0
|
58 |
CONST_LIT(KTableName3, "ctBl");
|
sl@0
|
59 |
CONST_LIT(KTableName4, "dTbL");
|
sl@0
|
60 |
CONST_LIT(KProtDb1ZName, "z:A.db");
|
sl@0
|
61 |
CONST_LIT(KProtDb1CName, "c:a.db");
|
sl@0
|
62 |
CONST_LIT(KProtDb2CName, "C:B.DB");
|
sl@0
|
63 |
CONST_LIT(KProtDb3CName, "c:z.DB");
|
sl@0
|
64 |
|
sl@0
|
65 |
CONST_LIT(KCol1, "ID");
|
sl@0
|
66 |
CONST_LIT(KCol2, "DATA1");
|
sl@0
|
67 |
CONST_LIT(KCol3, "DATA2");
|
sl@0
|
68 |
|
sl@0
|
69 |
#endif//T_DBPLATSECDEF_H
|