|
1 /* |
|
2 * Copyright (c) 2004 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 the License "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 * This file contains definitions used by Download Mgr Server. |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef __DOWNLOADMGR_DEF_H__ |
|
21 #define __DOWNLOADMGR_DEF_H__ |
|
22 |
|
23 #include <e32base.h> |
|
24 |
|
25 //the server version. A version must be specifyed when creating a session with the server |
|
26 const TUint KDownloadMgrMajorVersionNumber=0; |
|
27 const TUint KDownloadMgrMinorVersionNumber=1; |
|
28 const TUint KDownloadMgrBuildVersionNumber=1; |
|
29 |
|
30 const TUint KDefaultHeapSize = 0x10000; |
|
31 const TUint KDefaultMaxHeapSize = 0x200000; |
|
32 |
|
33 const TInt KDownloadMgrShutdownInterval = 10000000; |
|
34 |
|
35 // Literals |
|
36 _LIT( KDownloadMgrServerName, "DownloadMgrServer" ); |
|
37 _LIT( KDownloadMgrMainThreadName, "!DownloadMgrServer" ); |
|
38 _LIT( KDownloadMgrServerSemaphore, "DownloadMgrStartupSemaphore" ); |
|
39 _LIT( KDownloadMgrServerExe, "DownloadMgrServer.exe" ); |
|
40 #if defined(__WINS__) |
|
41 _LIT( KDownloadMgrServerDllName, "DownloadMgr.dll"); |
|
42 #endif |
|
43 |
|
44 // Server UID |
|
45 const TUid KUidDownloadMgrSrvExe = { 0x10008D60 }; |
|
46 const TUid KUidDownloadMgrClntSrv = { 0x10008D5F }; |
|
47 |
|
48 //opcodes used in message passing between client and server |
|
49 enum TDownloadMgrRqst |
|
50 { |
|
51 EHttpDownloadMgrInitialize, // = 0 |
|
52 EHttpDownloadMgrCreateDownload, // = 1 |
|
53 EHttpDownloadMgrUnused, // = 2 |
|
54 EHttpDownloadMgrAttach, // = 3 |
|
55 EHttpDownloadMgrPauseAll, // = 4 |
|
56 EHttpDownloadMgrStartAllL, // = 5 |
|
57 EHttpDownloadMgrResetAll, // = 6 |
|
58 EHttpDownloadMgrDeleteAll, // = 7 |
|
59 EHttpDownloadMgrDisconnect, // = 8 |
|
60 |
|
61 EHttpDownloadMgrGetIntAttribute, // = 9 |
|
62 EHttpDownloadMgrGetBoolAttribute, // =10 |
|
63 EHttpDownloadMgrGetStringAttribute, // =11 |
|
64 EHttpDownloadMgrGetString8Attribute, // =12 |
|
65 |
|
66 EHttpDownloadMgrSetIntAttribute, // =13 |
|
67 EHttpDownloadMgrSetBoolAttribute, // =14 |
|
68 EHttpDownloadMgrSetStringAttribute, // =15 |
|
69 EHttpDownloadMgrSetString8Attribute, // =16 |
|
70 EHttpDownloadMgrSessionEventSubscription, // =17 |
|
71 EHttpDownloadMgrSessionEventCancel, // =18 |
|
72 |
|
73 EHttpDownloadAttach, // =19 |
|
74 EHttpDownloadStart, // =20 |
|
75 EHttpDownloadPause, // =21 |
|
76 EHttpDownloadReset, // =22 |
|
77 EHttpDownloadDelete, // =23 |
|
78 EHttpDownloadMove, // =24 |
|
79 EHttpDownloadClose, // =25 |
|
80 EHttpDownloadEventSubscription, // =26 |
|
81 EHttpDownloadEventCancel, // =27 |
|
82 |
|
83 EHttpDownloadGetIntAttribute, // =28 |
|
84 EHttpDownloadGetBoolAttribute, // =29 |
|
85 EHttpDownloadGetStringAttribute, // =30 |
|
86 EHttpDownloadGetString8Attribute, // =31 |
|
87 |
|
88 EHttpDownloadSetIntAttribute, // =32 |
|
89 EHttpDownloadSetBoolAttribute, // =33 |
|
90 EHttpDownloadSetStringAttribute, // =34 |
|
91 EHttpDownloadSetString8Attribute, // =35 |
|
92 EHttpDownloadBufferAttributes, // =36 |
|
93 |
|
94 EHttpDownloadGetRFile, // =37 |
|
95 EHttpDownloadSetRFile, // =38 |
|
96 EHttpDownloadSetOnError, // =39 |
|
97 EHttpDownloadAttachToDownload, // =40 |
|
98 |
|
99 // Define your item here! EHttpDownload... // =n |
|
100 EHttpDownloadCloseCompleted, // =41 |
|
101 |
|
102 EHttpDownloadDataAttribute, // =42 |
|
103 EHttpDownloadTrackAttribute, // =43 |
|
104 |
|
105 /* |
|
106 * This should be the last item and the opcode must be incremented as well. |
|
107 * It is also important to make the changes on KDMgrServerPolicyRanges |
|
108 * in DownloadMgrServer.cpp according to this!!! |
|
109 */ |
|
110 EHttpDownloadMgrNotSupported // =44 (n+1) |
|
111 }; |
|
112 |
|
113 #endif /* __DOWNLOADMGR_DEF_H__ */ |
|
114 |