25
|
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: Globals for Content Publisher server
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
#ifndef C_CPSERVERDEF_H
|
|
20 |
#define C_CPSERVERDEF_H
|
|
21 |
|
|
22 |
// CONSTANTS
|
|
23 |
const TUint KCPServerMajorVersionNumber = 0;
|
|
24 |
const TUint KCPServerMinorVersionNumber = 1;
|
|
25 |
const TUint KCPServerBuildVersionNumber = 1;
|
|
26 |
|
|
27 |
// ENUMERATIONS
|
|
28 |
// Opcodes used in message passing between client and server
|
|
29 |
enum TCpServerRqst
|
|
30 |
{
|
|
31 |
ECpServerAddData = 1,
|
|
32 |
ECpServerRemoveData = 2,
|
|
33 |
ECpServerAddDataNonPersistent = 3,
|
|
34 |
ECpServerGetListSize = 10,
|
|
35 |
ECpServerGetListData = 11,
|
|
36 |
ECpServerRegisterObserver = 20,
|
|
37 |
ECpServerUnRegisterObserver = 21,
|
|
38 |
ECpServerGetChangeInfoData = 22,
|
|
39 |
ECpServerAddObserver = 23,
|
|
40 |
ECpServerRemoveObserver = 24,
|
|
41 |
ECpServerExecuteAction = 30,
|
|
42 |
ECpServerInternal = 100
|
|
43 |
};
|
|
44 |
|
|
45 |
_LIT( KCPServerThreadName, "cpserver_MainThread" );
|
|
46 |
_LIT( KCPServerName, "cpserver" );
|
|
47 |
_LIT( KCPServerFilename, "cpserver" );
|
|
48 |
_LIT( KActiveDes, "1" );
|
|
49 |
_LIT( KInActiveDes, "0" );
|
|
50 |
_LIT( KColon, ":" );
|
|
51 |
_LIT( KSemiColon, ";" );
|
|
52 |
|
|
53 |
_LIT( KCPServerPluginThreadName, "CPS plugin command execution thread %d" );
|
|
54 |
const TInt KCPServerPluginThreadMinHeapSize = 0x400; // 1kB
|
|
55 |
const TInt KCPServerPluginThreadMaxHeapSize = 0x100000; // 1MB
|
|
56 |
|
|
57 |
const TUid KServerUid3 =
|
|
58 |
{
|
|
59 |
0x20016B7B
|
|
60 |
};
|
|
61 |
|
|
62 |
/** Panic Category */
|
|
63 |
|
|
64 |
/** Active Data Server panic codes */
|
|
65 |
enum TCPServerPanic
|
|
66 |
{
|
|
67 |
ECPServerBadRequest = 1,
|
|
68 |
ECPServerBadDescriptor = 2,
|
|
69 |
ECPServerSrvCreateServer = 3
|
|
70 |
};
|
|
71 |
|
|
72 |
const TUint KDescriptorPosition( 0);
|
|
73 |
const TUint KReturnPosition( 1);
|
|
74 |
const TUint KInfoPosition( 2);
|
|
75 |
const TUint KTransactionPosition( 3);
|
|
76 |
const TBool KActive( ETrue );
|
|
77 |
const TBool KInActive( EFalse );
|
|
78 |
|
|
79 |
// Uid of CP Server
|
|
80 |
const TUid KServerUid = { 0x20016B7B };
|
|
81 |
// Uid of cpstorage
|
|
82 |
const TUint32 KCPStorageUid = { 0x20016B7C };
|
|
83 |
//Values of KSQLDBStateKey key
|
|
84 |
const TInt KSQLDBStateNormal = 0x00000001;
|
|
85 |
const TInt KSQLDBStateRestored = 0x00000002;//KSQLDBStateNormal << 1
|
|
86 |
// const ITnt NextState = LastState << 1;
|
|
87 |
|
|
88 |
|
|
89 |
|
|
90 |
#endif // C_CPSERVERDEF_H
|