44 #ifndef _CL_EVENT_API_H_
45 # define _CL_EVENT_API_H_
67 # define CL_EVENT_LOCAL_CHANNEL (0x0)
72 # define CL_EVENT_GLOBAL_CHANNEL (0x1)
77 # define CL_EVENT_CHANNEL_SUBSCRIBER (0x2)
82 # define CL_EVENT_CHANNEL_PUBLISHER (0x4)
87 # define CL_EVENT_CHANNEL_CREATE (0x8)
92 # define CL_EVENT_HIGHEST_PRIORITY (0x0)
97 # define CL_EVENT_LOWEST_PRIORITY (0x3)
102 # define CL_EVENT_VERSION {(ClUint8T)'B', 0x1, 0x1}
103 # define CL_EVENT_VERSION_SET(version) (version).releaseCode = (ClUint8T)'B', \
104 (version).majorVersion = 0x1,\
105 (version).minorVersion = 0x1
234 ClInvocationT invocation,
262 } ClEventVersionCallbacksT;
443 CL_IN const ClEventVersionCallbacksT *pEvtCallbackTable,
444 CL_IN ClUint32T numCallbacks,
484 ClSelectionObjectT * pSelectionObject);
677 CL_IN ClInvocationT invocation,
800 CL_IN ClUint8T version,
1124 CL_IN const void *pEventData,
1189 CL_IN void *pCookie);
Typical defines found in any software project.
Common Error Codes shared across multiple Clovis ASP Components.
Header file of Clovis Container Related APIs.
Header file of Event Manager Error Codes.
Operating System Abstraction Layer API.
ClUint32T ClRcT
Clovis return code type.
Definition: clCommon.h:168
#define CL_INOUT
CL_INOUT macro assists in clearly defining arguments of an API, but has no actual meaning.
Definition: clCommon.h:108
ClInt64T ClTimeT
Time duration specified in nanoseconds.
Definition: clCommon.h:154
#define CL_OUT
CL_OUT macro assists in clearly defining arguments of an API, but has no actual meaning.
Definition: clCommon.h:110
ClDispatchFlagsT
Dispatch flags.
Definition: clCommon.h:260
ClUint64T ClSizeT
Definition: clCommon.h:157
#define CL_IN
CL_IN macro assists in clearly defining arguments of an API, but has no actual meaning.
Definition: clCommon.h:106
ClRcT clEventCookieGet(CL_IN ClEventHandleT eventHandle, CL_OUT void **ppCookie)
Returns the cookie.
ClRcT clEventFinalize(CL_IN ClEventInitHandleT evtHandle)
Finalizes EM library.
ClRcT clEventFree(CL_IN ClEventHandleT eventHandle)
Frees an event header.
ClRcT clEventSelectionObjectGet(ClEventInitHandleT evtHandle, ClSelectionObjectT *pSelectionObject)
Helps detect pending callbacks.
ClRcT clEventInitialize(CL_OUT ClEventInitHandleT *pEvtHandle, CL_IN const ClEventCallbacksT *pEvtCallbacks, CL_INOUT ClVersionT *pVersion)
Initializes EM library.
ClRcT clEventAttributesSet(CL_IN ClEventHandleT eventHandle, CL_IN const ClEventPatternArrayT *pPatternArray, CL_IN ClEventPriorityT priority, CL_IN ClTimeT retentionTime, CL_IN const ClNameT *pPublisherName)
Sets the event attributes.
ClRcT clEventAttributesGet(CL_IN ClEventHandleT eventHandle, CL_IN ClEventPatternArrayT *pPatternArray, CL_OUT ClEventPriorityT *pPriority, CL_OUT ClTimeT *pRetentionTime, CL_OUT ClNameT *pPublisherName, CL_OUT ClTimeT *pPublishTime, CL_OUT ClEventIdT *pEventId)
Returns the event attributes.
ClUint8T ClEventPriorityT
Event priority type - it ranges from CL_EVENT_LOWEST_PRIORITY to CL_EVENT_HIGHEST_PRIORITY.
Definition: clEventApi.h:121
ClRcT clEventChannelOpenAsync(CL_IN ClEventInitHandleT evtHandle, CL_IN ClInvocationT invocation, CL_IN const ClNameT *pEvtChannelName, CL_IN ClEventChannelOpenFlagsT channelOpenFlags)
Opens an event channel asynchronously.
ClRcT clEventPublish(CL_IN ClEventHandleT eventHandle, CL_IN const void *pEventData, CL_IN ClSizeT eventDataSize, CL_OUT ClEventIdT *pEventId)
Publishes an event.
ClHandleT ClEventChannelHandleT
The type of a handle to an open event channel.
Definition: clEventApi.h:164
ClRcT clEventUnsubscribe(CL_IN ClEventChannelHandleT channelHandle, CL_IN ClEventSubscriptionIdT subscriptionId)
Unsubscribes from an event.
ClRcT clEventDispatch(ClEventInitHandleT evtHandle, ClDispatchFlagsT dispatchFlags)
Invokes the pending callback in context of the EO.
void(* ClEventChannelOpenCallbackT)(ClInvocationT invocation, ClEventChannelHandleT channelHandle, ClRcT error)
Open channel callback.
Definition: clEventApi.h:233
ClHandleT ClEventInitHandleT
The type of the handle supplied by the EM to an EO during the initialization of the EM library.
Definition: clEventApi.h:153
ClRcT clEventSubscribe(CL_IN ClEventChannelHandleT channelHandle, CL_IN const ClEventFilterArrayT *pFilters, CL_IN ClEventSubscriptionIdT subscriptionId, CL_IN void *pCookie)
Subscribes to an event identified by an event type (filter).
ClUint32T ClEventSubscriptionIdT
The type of an identifier for a particular subscription by a particular EO on a particular event chan...
Definition: clEventApi.h:171
ClRcT clEventAllocate(CL_IN ClEventChannelHandleT channelHandle, CL_OUT ClEventHandleT *pEventHandle)
Allocates an event header.
ClRcT clEventChannelOpen(CL_IN ClEventInitHandleT evtHandle, CL_IN const ClNameT *pEvtChannelName, CL_IN ClEventChannelOpenFlagsT evtChannelOpenFlag, CL_IN ClTimeT timeout, CL_OUT ClEventChannelHandleT *pChannelHandle)
Opens an event channel.
void(* ClEventDeliverCallbackT)(ClEventSubscriptionIdT subscriptionId, ClEventHandleT eventHandle, ClSizeT eventDataSize)
Event delivery callback.
Definition: clEventApi.h:206
ClRcT clEventChannelClose(CL_IN ClEventChannelHandleT channelHandle)
Closes an event channel.
ClUint64T ClEventIdT
The type of an event identifier.
Definition: clEventApi.h:115
ClUint8T ClEventChannelOpenFlagsT
Event Channel open flag.
Definition: clEventApi.h:140
ClRcT clEventDataGet(CL_IN ClEventHandleT eventHandle, CL_INOUT void *pEventData, CL_INOUT ClSizeT *pEventDataSize)
Returns data associated with an earlier event.
ClHandleT ClEventHandleT
The type of a handle to an event.
Definition: clEventApi.h:158
ClEventFilterTypeT
Filter Related Information.
Definition: clEventApi.h:324
ClRcT clEventChannelUnlink(CL_IN ClEventInitHandleT evtHandle, CL_IN const ClNameT *pEvtChannelName)
Deletes an event channel.
@ CL_EVENT_EXACT_FILTER
The entire filter must exactly match the entire event pattern.
Definition: clEventApi.h:336
@ CL_EVENT_PASS_ALL_FILTER
Always matches, regardless of the filter or event pattern.
Definition: clEventApi.h:340
@ CL_EVENT_SUFFIX_FILTER
The entire filter must match the last filterSize characters of the event pattern.
Definition: clEventApi.h:332
@ CL_EVENT_PREFIX_FILTER
The entire filter must match the first filterSize characters of the event pattern.
Definition: clEventApi.h:328
A name.
Definition: clCommon.h:197
Version Information for various services.
Definition: clCommon.h:250
The callback structure supplied by an EO to the EM containing the callback functions that can be invo...
Definition: clEventApi.h:244
ClEventDeliverCallbackT clEvtEventDeliverCallback
Event delivery callback.
Definition: clEventApi.h:254
ClEventChannelOpenCallbackT clEvtChannelOpenCallback
Asynchronous Channel open callback.
Definition: clEventApi.h:249
An Event pattern may contain a name (for example: a process name, checkpoint name,...
Definition: clEventApi.h:276
ClSizeT patternSize
Actual size of the buffer allocated to receive the pattern value.
Definition: clEventApi.h:286
ClUint8T * pPattern
Pointer to a buffer where the pattern value will be copied.
Definition: clEventApi.h:291
ClSizeT allocatedSize
Size of the buffer allocated to receive the pattern value.
Definition: clEventApi.h:281
The type of an event pattern array.
Definition: clEventApi.h:299
ClEventPatternT * pPatterns
Pointer to a buffer where the array of pattern will be copied.
Definition: clEventApi.h:314
ClSizeT allocatedNumber
Number of entries allocated in the pattern buffer.
Definition: clEventApi.h:304
ClSizeT patternsNumber
Actual number of patterns in the event.
Definition: clEventApi.h:309
The event filter structure defines the filter type and the filter pattern to be applied on an event p...
Definition: clEventApi.h:350
ClEventFilterTypeT filterType
Filter type.
Definition: clEventApi.h:355
ClEventPatternT filter
Filter pattern information.
Definition: clEventApi.h:360
The event filter array structure defines one or more filters.
Definition: clEventApi.h:375
ClSizeT filtersNumber
Number of filters.
Definition: clEventApi.h:380
ClEventFilterT * pFilters
Pointer to filter pattern.
Definition: clEventApi.h:385