williamr@4
|
1 |
// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
|
williamr@4
|
2 |
// All rights reserved.
|
williamr@4
|
3 |
// This component and the accompanying materials are made available
|
williamr@4
|
4 |
// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
|
williamr@4
|
5 |
// which accompanies this distribution, and is available
|
williamr@4
|
6 |
// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
|
williamr@4
|
7 |
//
|
williamr@4
|
8 |
// Initial Contributors:
|
williamr@4
|
9 |
// Nokia Corporation - initial contribution.
|
williamr@4
|
10 |
//
|
williamr@4
|
11 |
// Contributors:
|
williamr@4
|
12 |
//
|
williamr@4
|
13 |
// Description:
|
williamr@4
|
14 |
// Definitions used between the Core Dump Server interface library and the server.
|
williamr@4
|
15 |
//
|
williamr@4
|
16 |
|
williamr@4
|
17 |
|
williamr@4
|
18 |
|
williamr@4
|
19 |
/**
|
williamr@4
|
20 |
@file
|
williamr@4
|
21 |
@publishedPartner
|
williamr@4
|
22 |
@released
|
williamr@4
|
23 |
*/
|
williamr@4
|
24 |
|
williamr@4
|
25 |
#ifndef CORE_DUMP_SERVER_API_H
|
williamr@4
|
26 |
#define CORE_DUMP_SERVER_API_H
|
williamr@4
|
27 |
|
williamr@4
|
28 |
#include <plugindata.h>
|
williamr@4
|
29 |
|
williamr@4
|
30 |
/** Core Dump Server executable name */
|
williamr@4
|
31 |
_LIT(KCoreDumpServerName, "coredump_svr");
|
williamr@4
|
32 |
|
williamr@4
|
33 |
/** Core Dump Server UID */
|
williamr@4
|
34 |
const TUid KCoreDumpServUid = { 0x10282FE5 };
|
williamr@4
|
35 |
|
williamr@4
|
36 |
/** Core Dump Server major version */
|
williamr@4
|
37 |
const TUint KCoreDumpServMajorVersionNumber=1;
|
williamr@4
|
38 |
|
williamr@4
|
39 |
/** Core Dump Server minor version */
|
williamr@4
|
40 |
const TUint KCoreDumpServMinorVersionNumber=0;
|
williamr@4
|
41 |
|
williamr@4
|
42 |
/** Core Dump Server build number */
|
williamr@4
|
43 |
const TUint KCoreDumpServBuildVersionNumber=1;
|
williamr@4
|
44 |
|
williamr@4
|
45 |
/**
|
williamr@4
|
46 |
Core Dump Server client-server requests
|
williamr@4
|
47 |
@internalTechnology
|
williamr@4
|
48 |
*/
|
williamr@4
|
49 |
enum TCoreDumpServRqst
|
williamr@4
|
50 |
{
|
williamr@4
|
51 |
/** Obtain a plugin list.
|
williamr@4
|
52 |
@see RCoreDumpSession::GetPluginListL(). */
|
williamr@4
|
53 |
ECoreDumpServGetPluginList,
|
williamr@4
|
54 |
|
williamr@4
|
55 |
/** Generic call to obtain data about a list from the Core Dump Server.
|
williamr@4
|
56 |
@see RCoreDumpSession::GetListLC(). */
|
williamr@4
|
57 |
ECoreDumpGetListInfo,
|
williamr@4
|
58 |
|
williamr@4
|
59 |
/** Generic call to obtain the list from the Core Dump Server.
|
williamr@4
|
60 |
@see RCoreDumpSession::GetListLC(). */
|
williamr@4
|
61 |
ECoreDumpGetListData,
|
williamr@4
|
62 |
|
williamr@4
|
63 |
/** Request the loading or unloading of a plugin.
|
williamr@4
|
64 |
@see RCoreDumpSession::PluginRequestL(). */
|
williamr@4
|
65 |
ECoreDumpPluginRequest,
|
williamr@4
|
66 |
|
williamr@4
|
67 |
/** Obtain the current number of configuration parameters.
|
williamr@4
|
68 |
@see RCoreDumpSession::GetNumberConfigParametersL(). */
|
williamr@4
|
69 |
ECoreDumpGetNumberConfigParams,
|
williamr@4
|
70 |
|
williamr@4
|
71 |
/** Obtain a configuration parameter.
|
williamr@4
|
72 |
@see RCoreDumpSession::GetConfigParameterL(). */
|
williamr@4
|
73 |
ECoreDumpGetConfigParam,
|
williamr@4
|
74 |
|
williamr@4
|
75 |
/** Change a configuration parameter.
|
williamr@4
|
76 |
@see RCoreDumpSession::SetConfigParameterL(). */
|
williamr@4
|
77 |
ECoreDumpSetConfigParam,
|
williamr@4
|
78 |
|
williamr@4
|
79 |
|
williamr@4
|
80 |
/** Unused */
|
williamr@4
|
81 |
ECoreDumpAttachThread,
|
williamr@4
|
82 |
|
williamr@4
|
83 |
/** Unused */
|
williamr@4
|
84 |
ECoreDumpDetachThread,
|
williamr@4
|
85 |
|
williamr@4
|
86 |
/** Unused */
|
williamr@4
|
87 |
ECoreDumpAttachProcess,
|
williamr@4
|
88 |
|
williamr@4
|
89 |
/** Unused */
|
williamr@4
|
90 |
ECoreDumpDetachProcess,
|
williamr@4
|
91 |
|
williamr@4
|
92 |
/** Request the observation of a target or the cancellation of an observation.
|
williamr@4
|
93 |
@see RCoreDumpSession::ObservationRequestL(). */
|
williamr@4
|
94 |
ECoreDumpObservationRequest,
|
williamr@4
|
95 |
|
williamr@4
|
96 |
/** Request the restoration of a configuration.
|
williamr@4
|
97 |
@see RCoreDumpSession::LoadConfigL(). */
|
williamr@4
|
98 |
ECoreDumpLoadConfig,
|
williamr@4
|
99 |
|
williamr@4
|
100 |
/** Request the saving of a configuration.
|
williamr@4
|
101 |
@see RCoreDumpSession::SaveConfigL(). */
|
williamr@4
|
102 |
ECoreDumpSaveConfig,
|
williamr@4
|
103 |
|
williamr@4
|
104 |
/** Guard */
|
williamr@4
|
105 |
ECoreDumpServEndMarker
|
williamr@4
|
106 |
|
williamr@4
|
107 |
};
|
williamr@4
|
108 |
|
williamr@4
|
109 |
/** Number of asynchronous requests */
|
williamr@4
|
110 |
#define KTTMaxAsyncRequests (4)
|
williamr@4
|
111 |
|
williamr@4
|
112 |
/** Default number of message slots per session
|
williamr@4
|
113 |
Same as KTTMaxAsyncRequests as synchronous requests provided
|
williamr@4
|
114 |
by framework */
|
williamr@4
|
115 |
#define KTTDefaultMessageSlots (KTTMaxAsyncRequests)
|
williamr@4
|
116 |
|
williamr@4
|
117 |
|
williamr@4
|
118 |
/**
|
williamr@4
|
119 |
@internalTechnology
|
williamr@4
|
120 |
Number of plugin details in a plugin transfer block.
|
williamr@4
|
121 |
Used between server library and cds
|
williamr@4
|
122 |
*/
|
williamr@4
|
123 |
#define KNumPluginDetails 5
|
williamr@4
|
124 |
|
williamr@4
|
125 |
|
williamr@4
|
126 |
/**
|
williamr@4
|
127 |
@internalTechnology
|
williamr@4
|
128 |
Class used for transfering fixed sized blocks of plugin information
|
williamr@4
|
129 |
between the Core Dump Server and its clients. This makes it easier
|
williamr@4
|
130 |
accross the client/server interface.
|
williamr@4
|
131 |
@see TPluginInfo
|
williamr@4
|
132 |
*/
|
williamr@4
|
133 |
class TPluginInfoBlock
|
williamr@4
|
134 |
{
|
williamr@4
|
135 |
public:
|
williamr@4
|
136 |
|
williamr@4
|
137 |
/**
|
williamr@4
|
138 |
A simple array is used as the transfer block across the
|
williamr@4
|
139 |
process boundary.
|
williamr@4
|
140 |
*/
|
williamr@4
|
141 |
TPluginInfo plugins[ KNumPluginDetails ];
|
williamr@4
|
142 |
};
|
williamr@4
|
143 |
|
williamr@4
|
144 |
|
williamr@4
|
145 |
/**
|
williamr@4
|
146 |
Enumerations that identify the RProperty objects shared between various parts
|
williamr@4
|
147 |
of the core dump server system, plugins and clients.
|
williamr@4
|
148 |
|
williamr@4
|
149 |
The properties are defined by the Core Dump Session at startup.
|
williamr@4
|
150 |
These properties have the uid of the Core Dump Server.
|
williamr@4
|
151 |
|
williamr@4
|
152 |
@publishedPartner
|
williamr@4
|
153 |
@released
|
williamr@4
|
154 |
@see CCoreDumpSession::ConstructL().
|
williamr@4
|
155 |
*/
|
williamr@4
|
156 |
enum TCrashProgress
|
williamr@4
|
157 |
{
|
williamr@4
|
158 |
/** Current crash status. Updated by formatters during a crash.
|
williamr@4
|
159 |
RProperty of type RProperty::EText. */
|
williamr@4
|
160 |
ECrashProgress,
|
williamr@4
|
161 |
|
williamr@4
|
162 |
/** Cancels the generation of a crash when set to non-zero.
|
williamr@4
|
163 |
RProperty of type RProperty::EInt. */
|
williamr@4
|
164 |
ECancelCrash,
|
williamr@4
|
165 |
|
williamr@4
|
166 |
/** Number of crashes served by this session of the Core Dump Server.
|
williamr@4
|
167 |
RProperty of type RProperty::EInt. */
|
williamr@4
|
168 |
ECrashCount
|
williamr@4
|
169 |
};
|
williamr@4
|
170 |
|
williamr@4
|
171 |
|
williamr@4
|
172 |
|
williamr@4
|
173 |
/**
|
williamr@4
|
174 |
@publishedPartner
|
williamr@4
|
175 |
@released
|
williamr@4
|
176 |
|
williamr@4
|
177 |
Class for requesting lists from the Core Dump Server.
|
williamr@4
|
178 |
The requestor appends the results of each request to obtain an entire list.
|
williamr@4
|
179 |
Uses "T<type>InfoBlock" classes to transfer data accross the process boundary.
|
williamr@4
|
180 |
*/
|
williamr@4
|
181 |
class TListRequest
|
williamr@4
|
182 |
{
|
williamr@4
|
183 |
public:
|
williamr@4
|
184 |
|
williamr@4
|
185 |
/** Type of data to supply for this request */
|
williamr@4
|
186 |
enum TListRequestType
|
williamr@4
|
187 |
{
|
williamr@4
|
188 |
/** This request is for the formatter plugin list */
|
williamr@4
|
189 |
EFormatterList,
|
williamr@4
|
190 |
|
williamr@4
|
191 |
/** This request is for the writer plugin list */
|
williamr@4
|
192 |
EWriterList,
|
williamr@4
|
193 |
|
williamr@4
|
194 |
/** This request is for the thread list */
|
williamr@4
|
195 |
EThreadList,
|
williamr@4
|
196 |
|
williamr@4
|
197 |
/** This request is for the process list */
|
williamr@4
|
198 |
EProcessList,
|
williamr@4
|
199 |
|
williamr@4
|
200 |
/** This request is for the executable list */
|
williamr@4
|
201 |
EExecutableList,
|
williamr@4
|
202 |
|
williamr@4
|
203 |
/**
|
williamr@4
|
204 |
@internalTechnology
|
williamr@4
|
205 |
Last marker
|
williamr@4
|
206 |
*/
|
williamr@4
|
207 |
EUnknownRequest
|
williamr@4
|
208 |
|
williamr@4
|
209 |
};
|
williamr@4
|
210 |
|
williamr@4
|
211 |
/** Type of data to supply for this request */
|
williamr@4
|
212 |
TListRequestType iListType;
|
williamr@4
|
213 |
|
williamr@4
|
214 |
/** Sub identifiers for the request. These are auxiliary ids that
|
williamr@4
|
215 |
can be used to refine the request. */
|
williamr@4
|
216 |
TUint32 iSubId1;
|
williamr@4
|
217 |
TUint32 iSubId2;
|
williamr@4
|
218 |
|
williamr@4
|
219 |
/** Requestor sets iIndex. iIndex==0 means the supplier should refresh the
|
williamr@4
|
220 |
list and supply from index 0. iIndex > 0 means supply element
|
williamr@4
|
221 |
[iIndex-1] and onwards. Requestor should thus increase iIndex
|
williamr@4
|
222 |
by how many elements were supplied on each call. */
|
williamr@4
|
223 |
TUint iIndex;
|
williamr@4
|
224 |
|
williamr@4
|
225 |
/** Supplier writes iSupplied according to how many items
|
williamr@4
|
226 |
it copied into the buffer on this call */
|
williamr@4
|
227 |
TUint iSupplied;
|
williamr@4
|
228 |
|
williamr@4
|
229 |
/** Supplier writes iRemaining to indicate how many items it
|
williamr@4
|
230 |
has yet to supply. */
|
williamr@4
|
231 |
TUint iRemaining;
|
williamr@4
|
232 |
|
williamr@4
|
233 |
/** Number of bytes required to hold the resulting data */
|
williamr@4
|
234 |
TUint iRequiredDescriptorSize;
|
williamr@4
|
235 |
|
williamr@4
|
236 |
/**
|
williamr@4
|
237 |
Spare variables for future expansion.
|
williamr@4
|
238 |
@internalTechnology */
|
williamr@4
|
239 |
TUint32 iSpare0;
|
williamr@4
|
240 |
/** @internalTechnology */
|
williamr@4
|
241 |
TUint32 iSpare1;
|
williamr@4
|
242 |
/** @internalTechnology */
|
williamr@4
|
243 |
TUint32 iSpare2;
|
williamr@4
|
244 |
/** @internalTechnology */
|
williamr@4
|
245 |
TUint32 iSpare3;
|
williamr@4
|
246 |
|
williamr@4
|
247 |
};
|
williamr@4
|
248 |
|
williamr@4
|
249 |
|
williamr@4
|
250 |
|
williamr@4
|
251 |
#endif // CORE_DUMP_SERVER_API_H
|