Main Page
Related Pages
Modules
Classes
Files
File List
File Members
src
SAFplus
components
eo
include
clEoConfigApi.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2002-2012 OpenClovis Solutions Inc. All Rights Reserved.
3
*
4
* This file is available under a commercial license from the
5
* copyright holder or the GNU General Public License Version 2.0.
6
*
7
* The source code for this program is not published or otherwise
8
* divested of its trade secrets, irrespective of what has been
9
* deposited with the U.S. Copyright office.
10
*
11
* This program is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14
* General Public License for more details.
15
*
16
* For more information, see the file COPYING provided with this
17
* material.
18
*/
19
/*******************************************************************************
20
* ModuleName : eo
21
* File : clEoConfigApi.h
22
*******************************************************************************/
23
24
/*******************************************************************************
25
* Description :
26
* This header contains Execution Object [EO] config definitions.
27
*
28
*
29
*****************************************************************************/
30
45
#ifndef _CL_EO_CONFIG_API_H_
46
#define _CL_EO_CONFIG_API_H_
47
48
#ifdef __cplusplus
49
extern
"C"
{
50
#endif
51
52
#include <
clCommon.h
>
53
54
55
/******************************************************************************
56
* Constant and Macro Definitions
57
*****************************************************************************/
58
63
typedef
ClUint64T
ClEoIdT
;
64
68
#define CL_EO_MAX_NAME_LEN 32
69
72
#define CL_EO_DEFAULT_THREADS 1
73
77
#define CL_EO_NAME clEoNameGet()
78
83
#define CL_EO_DEFAULT_NAME "3RD_PARTY_COMP"
84
85
86
87
/******************************************************************************
88
* Data Types
89
*****************************************************************************/
90
94
typedef
enum
{
95
99
CL_EO_STATE_INIT
= 0x1,
100
104
CL_EO_STATE_ACTIVE
= 0x2,
105
109
CL_EO_STATE_STDBY
= 0x4,
110
114
CL_EO_STATE_SUSPEND
= 0x8,
115
119
CL_EO_STATE_STOP
= 0x10,
120
124
CL_EO_STATE_KILL
= 0x20,
125
129
CL_EO_STATE_RESUME
= 0x40,
130
134
CL_EO_STATE_FAILED
= 0x80,
135
139
CL_EO_STATE_THREAD_SAFE
= 0x100,
140
144
CL_EO_STATE_BITS
= 9,
145
146
147
}
ClEoStateT
;
148
149
typedef
enum
{
150
156
CL_EO_USE_THREAD_FOR_RECV
=
CL_TRUE
,
157
164
CL_EO_USE_THREAD_FOR_APP
=
CL_FALSE
165
166
}
ClEoApplicationTypeT
;
167
168
typedef
enum
{
169
174
CL_EO_DONT_POLL
= 0,
175
180
CL_EO_BUSY_POLL
= 1,
181
186
CL_EO_DEFAULT_POLL
= 2
187
188
}
ClEoPollingTypeT
;
189
194
typedef
struct
{
195
199
ClEoPollingTypeT
freq
;
200
204
ClRcT
status
;
205
206
}
ClEoSchedFeedBackT
;
207
213
typedef
ClRcT
(*
ClEoAppCreateCallbackT
)(
214
218
CL_IN
ClUint32T argc,
219
223
CL_IN
char
*argv[]);
224
225
226
240
typedef
ClRcT
(*
ClEoAppStateChgCallbackT
)(
241
245
CL_IN
ClEoStateT
state);
246
250
typedef
ClRcT
(*
ClEoAppDeleteCallbackT
)();
251
255
typedef
ClRcT
(*
ClEoAppHealthCheckCallbackT
)(
256
260
CL_OUT
ClEoSchedFeedBackT
*schFeedback);
261
265
typedef
ClRcT
(*
ClEoCustomActionT
)(
ClCompIdT
compId, ClWaterMarkIdT wmId,
266
ClWaterMarkT *pWaterMark, ClEoWaterMarkFlagT wmType,
ClEoActionArgListT
argList);
267
272
typedef
struct
{
273
277
ClCharT EOname[
CL_EO_MAX_NAME_LEN
];
278
282
ClOsalThreadPriorityT
pri
;
283
287
ClUint32T
noOfThreads
;
288
292
ClIocPortT
reqIocPort
;
293
297
ClUint32T
maxNoClients
;
298
302
ClEoApplicationTypeT
appType
;
303
308
ClEoAppCreateCallbackT
clEoCreateCallout
;
309
314
ClEoAppDeleteCallbackT
clEoDeleteCallout
;
315
320
ClEoAppStateChgCallbackT
clEoStateChgCallout
;
321
326
ClEoAppHealthCheckCallbackT
clEoHealthCheckCallout
;
327
332
ClEoCustomActionT
clEoCustomAction
;
333
334
ClBoolT needSerialization;
335
336
}
ClEoConfigT
;
337
341
ClRcT
clEoProgNameGet
(ClCharT *pName,ClUint32T maxSize);
342
346
ClCharT*
clEoNameGet
(
void
);
347
348
/***********************************************************************/
349
/* external symbols we expect here */
350
/***********************************************************************/
351
352
/*
353
* This is the configuration for an EO. Since we can only do one EO
354
* per process in RC1, this can be here. But when support for multiple
355
* EOs per process shows up, this has to be fixed in some way.
356
*/
357
358
extern
ClEoConfigT
clEoConfig;
359
360
extern
ClCharT *clEoProgName;
361
362
#ifdef __cplusplus
363
}
364
365
#endif
366
367
#endif
/* _CL_EO_CONFIG_API_H_ */
368
Generated on Tue Jan 10 10:29:15 PST 2012 for OpenClovis SDK using
Doxygen