21 #ifndef CORRELATOR_PLUGIN_H
22 #define CORRELATOR_PLUGIN_H
24 #ifndef _AP_NO_DEPRECATED_PLUGINAPI_WARNING
26 #warning This API for writing EPL plugins is deprecated. Please use the API located in epl_plugin.hpp instead
28 #pragma message("correlator_plugin.h(0) Warning: This API for writing EPL plugins is deprecated. Please use the API located in epl_plugin.hpp instead")
33 #include <AP_Platform.h>
73 #define AP_CORRELATOR_PLUGIN_VERSION 0x00090000
86 AP_PLUGIN_SERIALISATION_EXCEPTION
104 struct AP_PluginCorrelatorInterface_Stubs;
105 struct AP_PluginContext_Stubs;
106 struct AP_PluginType_Stubs;
107 struct AP_PluginChunk_Stubs;
108 struct AP_PluginTypeList_Stubs;
110 typedef struct AP_PluginCorrelatorInterface_Stubs AP_PluginCorrelatorInterface;
111 typedef struct AP_PluginContext_Stubs AP_PluginContext;
112 typedef struct AP_PluginType_Stubs AP_PluginType;
113 typedef struct AP_PluginChunk_Stubs AP_PluginChunk;
114 typedef struct AP_PluginTypeList_Stubs AP_PluginTypeList;
140 void (AP_PLUGIN_CALL* sendEvent)(AP_PluginCorrelatorInterface* _interface,
const char* event);
155 void (AP_PLUGIN_CALL* sendEventTo)(AP_PluginCorrelatorInterface* _interface,
const char* event, AP_uint64 targetContext, AP_uint64 sourceContext);
172 struct AP_PluginCorrelatorInterface_Stubs {
176 void sendEvent(
char* event) {
180 void sendEvent(
char* event, AP_uint64 targetCtx, AP_uint64 sourceCtx) {
181 api.
functions->sendEventTo(
this, event, targetCtx, sourceCtx);
198 AP_uint32 (AP_PLUGIN_CALL* version)(
const AP_PluginContext* ctx);
214 void (AP_PLUGIN_CALL* deleteChunk)(
const AP_PluginContext* ctx, AP_PluginChunk* chunk);
217 AP_bool (AP_PLUGIN_CALL* checkException)(
const AP_PluginContext* ctx);
226 void (AP_PLUGIN_CALL* clearException)(
const AP_PluginContext* ctx);
230 AP_PluginCorrelatorInterface* (AP_PLUGIN_CALL*
getCorrelator)(
const AP_PluginContext* ctx);
241 AP_uint64 (AP_PLUGIN_CALL* getContextId)(
const AP_PluginContext* ctx);
252 const void* reserved;
258 struct AP_PluginContext_Stubs {
262 AP_uint32 version()
const {
270 void deleteChunk(AP_PluginChunk* chunk)
const {
274 AP_bool checkException()
const {
275 return api.
functions->checkException(
this);
279 return api.
functions->getExceptionType(
this);
282 const AP_char8* getExceptionMessage()
const {
286 void clearException()
const {
290 const AP_PluginCorrelatorInterface* getCorrelator()
const{
298 AP_uint64 getContextId()
const{
299 return api.
functions->getContextId(
this);
315 void* (AP_PLUGIN_CALL*
getUserData)(
const AP_PluginChunk* chunk);
322 void (AP_PLUGIN_CALL* setUserData)(AP_PluginChunk* chunk,
void* userData);
336 void (AP_PLUGIN_CALL* freeUserData)(AP_PluginChunk* chunk);
339 void* (AP_PLUGIN_CALL*
copyUserData)(
const AP_PluginChunk* chunk);
359 struct AP_PluginChunk_Stubs {
363 void* getUserData()
const {
367 void setUserData(
void* userData) {
368 api.
functions->setUserData(
this, userData);
371 void freeUserData() {
375 void* copyUserData() {
397 AP_PluginChunk* (AP_PLUGIN_CALL*
getChunkValue)(
const AP_PluginType* obj);
406 void (AP_PLUGIN_CALL* setChunkValue)(
const AP_PluginType* obj, AP_PluginChunk* val);
410 AP_int64 (AP_PLUGIN_CALL* getIntegerValue)(
const AP_PluginType* obj);
413 void (AP_PLUGIN_CALL* setIntegerValue)(AP_PluginType* obj,
AP_int64 val);
417 AP_float64 (AP_PLUGIN_CALL* getFloatValue)(
const AP_PluginType* obj);
420 void (AP_PLUGIN_CALL* setFloatValue)(AP_PluginType* obj,
AP_float64 val);
424 AP_decimal (AP_PLUGIN_CALL* getDecimalValue)(
const AP_PluginType* obj);
427 void (AP_PLUGIN_CALL* setDecimalValue)(AP_PluginType* obj,
AP_decimal val);
431 AP_bool (AP_PLUGIN_CALL* getBooleanValue)(
const AP_PluginType* obj);
434 void (AP_PLUGIN_CALL* setBooleanValue)(AP_PluginType* obj,
AP_bool val);
438 const AP_char8* (AP_PLUGIN_CALL*
getStringValue)(
const AP_PluginType* obj);
444 void (AP_PLUGIN_CALL* setStringValue)(AP_PluginType* obj,
const AP_char8* val);
448 AP_uint32 (AP_PLUGIN_CALL* getSequenceLength)(
const AP_PluginType* obj);
457 void (AP_PLUGIN_CALL* setSequenceLength)(
const AP_PluginType* obj,
AP_uint32 len);
480 void (AP_PLUGIN_CALL *copyFrom)(
const AP_PluginType *obj,
const AP_PluginType *other);
497 void (AP_PLUGIN_CALL* releaseSequenceElements)(
const AP_PluginType* obj);
518 void (AP_PLUGIN_CALL* releaseChunkSequenceElements)(
const AP_PluginType* obj);
535 void (AP_PLUGIN_CALL* releaseIntegerSequenceElements)(
const AP_PluginType* obj);
552 void (AP_PLUGIN_CALL* releaseFloatSequenceElements)(
const AP_PluginType* obj);
569 void (AP_PLUGIN_CALL* releaseDecimalSequenceElements)(
const AP_PluginType* obj);
586 void (AP_PLUGIN_CALL* releaseBooleanSequenceElements)(
const AP_PluginType* obj);
613 void (AP_PLUGIN_CALL* releaseStringSequenceElements)(
const AP_PluginType* obj);
630 struct AP_PluginType_Stubs {
635 return api.
functions->getDiscriminator(
this);
638 AP_PluginChunk* getChunkValue()
const {
642 void setChunkValue(AP_PluginChunk* val)
const {
646 AP_int64 getIntegerValue()
const {
647 return api.
functions->getIntegerValue(
this);
650 void setIntegerValue(AP_int64 val) {
651 api.
functions->setIntegerValue(
this, val);
654 AP_float64 getFloatValue()
const {
655 return api.
functions->getFloatValue(
this);
658 void setFloatValue(AP_float64 val) {
662 AP_decimal getDecimalValue()
const {
663 return api.
functions->getDecimalValue(
this);
666 void setDecimalValue(AP_decimal val) {
667 api.
functions->setDecimalValue(
this, val);
670 AP_bool getBooleanValue()
const {
671 return api.
functions->getBooleanValue(
this);
674 void setBooleanValue(AP_bool val) {
675 api.
functions->setBooleanValue(
this, val);
678 const AP_char8* getStringValue()
const {
682 void setStringValue(
const AP_char8* val) {
683 api.
functions->setStringValue(
this, val);
686 AP_uint32 getSequenceLength()
const {
687 return api.
functions->getSequenceLength(
this);
691 return api.
functions->getSequenceType(
this);
694 AP_PluginType* getSequenceElement(AP_uint32 index)
const {
698 void copyFrom(
const AP_PluginType *other) {
699 return api.
functions->copyFrom(
this, other);
702 AP_PluginType*
const *getSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
706 void releaseSequenceElements()
const {
707 api.
functions->releaseSequenceElements(
this);
710 AP_PluginChunk*
const * getChunkSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
714 void releaseChunkSequenceElements()
const {
715 api.
functions->releaseChunkSequenceElements(
this);
718 AP_int64* getIntegerSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
722 void releaseIntegerSequenceElements()
const {
723 api.
functions->releaseIntegerSequenceElements(
this);
726 AP_float64* getFloatSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
730 void releaseFloatSequenceElements()
const {
731 api.
functions->releaseFloatSequenceElements(
this);
734 AP_decimal* getDecimalSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
738 void releaseDecimalSequenceElements()
const {
739 api.
functions->releaseDecimalSequenceElements(
this);
742 AP_bool* getBooleanSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
746 void releaseBooleanSequenceElements()
const {
747 api.
functions->releaseBooleanSequenceElements(
this);
750 const AP_char8** getStringSequenceElements(AP_uint32 start = 0, AP_uint32 length = ~0U)
const {
754 void releaseStringSequenceElements()
const {
755 api.
functions->releaseStringSequenceElements(
this);
772 AP_uint32 (AP_PLUGIN_CALL* getSize)(
const AP_PluginTypeList* list);
775 AP_bool (AP_PLUGIN_CALL* isEmpty)(
const AP_PluginTypeList* list);
778 const AP_PluginType* (AP_PLUGIN_CALL*
getElement)(
const AP_PluginTypeList* list,
AP_uint32 index);
795 struct AP_PluginTypeList_Stubs {
799 AP_uint32 getSize()
const {
803 AP_bool isEmpty()
const {
807 const AP_PluginType* getElement(AP_uint32 index)
const {
947 typedef AP_PLUGIN_DLL_SYM
AP_ErrorCode (AP_PLUGIN_CALL* AP_PluginThreadEndedFunctionPtr) (
const AP_PluginContext* ctx);
[DEPRECATED] AP_TypeList
Definition: correlator_plugin.h:787
const AP_char8 *AP_PLUGIN_CALL * getExceptionMessage(const AP_PluginContext *ctx)
void *AP_PLUGIN_CALL * copyUserData(const AP_PluginChunk *chunk)
AP_PluginCorrelatorInterface *AP_PLUGIN_CALL * getCorrelator(const AP_PluginContext *ctx)
[DEPRECATED] CorrelatorInterface.
Definition: correlator_plugin.h:164
AP_uint32(AP_PLUGIN_CALL *getSequenceLength)(const AP_PluginType *obj)
AP_bool(AP_PLUGIN_CALL *checkException)(const AP_PluginContext *ctx)
AP_Capabilities
Definition: AP_PluginCommon.h:108
void(AP_PLUGIN_CALL * AP_PluginFunctionPtr)(const AP_PluginContext *ctx, const AP_PluginTypeList *args, AP_PluginType *rval, AP_TypeDiscriminator rtype)
Definition: correlator_plugin.h:822
[DEPRECATED] CorrelatorInterface function API.
Definition: correlator_plugin.h:129
[DEPRECATED] AP_TypeList function API
Definition: correlator_plugin.h:768
const struct AP_PluginTypeList_Functions * functions
Definition: correlator_plugin.h:792
AP_int64 *AP_PLUGIN_CALL * getIntegerSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
AP_PluginType *const *AP_PLUGIN_CALL * getSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
AP_PluginType *AP_PLUGIN_CALL * getSequenceElement(const AP_PluginType *obj, AP_uint32 index)
Incorrect type.
Definition: correlator_plugin.h:81
Generic exception.
Definition: correlator_plugin.h:79
AP_decimal *AP_PLUGIN_CALL * getDecimalSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
AP_uint32(AP_PLUGIN_CALL *getSize)(const AP_PluginTypeList *list)
const AP_char8 * returnType
Definition: correlator_plugin.h:854
const AP_char8 *AP_PLUGIN_CALL * getStringValue(const AP_PluginType *obj)
AP_uint64(AP_PLUGIN_CALL *getContextId)(const AP_PluginContext *ctx)
const struct AP_PluginType_Functions * functions
Definition: correlator_plugin.h:627
[DEPRECATED] PluginChunk function API.
Definition: correlator_plugin.h:311
AP_TypeDiscriminator
Definition: AP_PluginCommon.h:56
[DEPRECATED] PluginContext.
Definition: correlator_plugin.h:250
AP_PLUGIN_DLL_SYM AP_ErrorCode(AP_PLUGIN_CALL * AP_PluginShutdownFunctionPtr)(const AP_PluginContext *ctx)
Definition: correlator_plugin.h:892
AP_PluginFunctionPtr fptr
Definition: correlator_plugin.h:842
AP_uint32 nParams
Definition: correlator_plugin.h:846
AP_float64(AP_PLUGIN_CALL *getFloatValue)(const AP_PluginType *obj)
[DEPRECATED] AP_Type function API
Definition: correlator_plugin.h:389
const struct AP_PluginChunk_Functions * functions
Definition: correlator_plugin.h:353
void(AP_PLUGIN_CALL *deleteChunk)(const AP_PluginContext *ctx
[DEPRECATED] PluginChunk.
Definition: correlator_plugin.h:348
const struct AP_PluginChunk_Callbacks * callbacks
Definition: correlator_plugin.h:356
void(AP_PLUGIN_CALL *sendEvent)(AP_PluginCorrelatorInterface *_interface
[DEPRECATED] PluginChunk callback API.
Definition: correlator_plugin.h:332
const AP_char8 **AP_PLUGIN_CALL * getStringSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
const AP_char8 ** paramTypes
Definition: correlator_plugin.h:850
AP_float64 *AP_PLUGIN_CALL * getFloatSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
const struct AP_PluginCorrelatorInterface_Functions * functions
Definition: correlator_plugin.h:169
const AP_PluginType *AP_PLUGIN_CALL * getElement(const AP_PluginTypeList *list, AP_uint32 index)
AP_TypeDiscriminator(AP_PLUGIN_CALL *getDiscriminator)(const AP_PluginType *obj)
AP_CorrelatorPluginExceptionType
Definition: correlator_plugin.h:77
AP_decimal(AP_PLUGIN_CALL *getDecimalValue)(const AP_PluginType *obj)
AP_int64(AP_PLUGIN_CALL *getIntegerValue)(const AP_PluginType *obj)
void *AP_PLUGIN_CALL * getUserData(const AP_PluginChunk *chunk)
AP_PluginChunk *AP_PLUGIN_CALL * createChunk(const AP_PluginContext *ctx, const struct AP_PluginChunk_Callbacks *callbacks, void *userData)
AP_CorrelatorPluginExceptionType(AP_PLUGIN_CALL *getExceptionType)(const AP_PluginContext *ctx)
const struct AP_PluginContext_Functions * functions
Definition: correlator_plugin.h:255
const AP_char8 * name
Definition: correlator_plugin.h:838
Out of bands.
Definition: correlator_plugin.h:85
[DEPRECATED] PluginContext function API.
Definition: correlator_plugin.h:192
AP_bool(AP_PLUGIN_CALL *getBooleanValue)(const AP_PluginType *obj)
AP_PLUGIN_DLL_SYM AP_ErrorCode(AP_PLUGIN_CALL * AP_PluginVersionFunctionPtr)(const AP_PluginContext *ctx, AP_uint32 *version)
Definition: correlator_plugin.h:912
AP_PluginChunk *const *AP_PLUGIN_CALL * getChunkSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
void(AP_PLUGIN_CALL *freeUserData)(AP_PluginChunk *chunk)
AP_PLUGIN_DLL_SYM AP_ErrorCode(AP_PLUGIN_CALL *AP_PluginThreadEndedFunctionPtr)(const AP_PluginContext *ctx)
Definition: correlator_plugin.h:947
AP_ENGINE_CLIENT_API void char8free(char *string)
Free any char* string returned from the client API.
AP_PLUGIN_DLL_SYM AP_ErrorCode(AP_PLUGIN_CALL * AP_PluginInitFunctionPtr)(const AP_PluginContext *ctx, AP_uint32 *version, AP_uint32 *nFunctions, AP_PluginFunction **functions)
Definition: correlator_plugin.h:882
AP_bool *AP_PLUGIN_CALL * getBooleanSequenceElements(const AP_PluginType *obj, AP_uint32 start, AP_uint32 length)
AP_PLUGIN_DLL_SYM AP_Capabilities(AP_PLUGIN_CALL * AP_PluginGetCapabilitiesFunctionPtr)(const AP_PluginContext *ctx)
Definition: correlator_plugin.h:930
[DEPRECATED] Plugin function descriptor.
Definition: correlator_plugin.h:834
AP_uint32(AP_PLUGIN_CALL *version)(const AP_PluginContext *ctx)
[DEPRECATED] AP_Type
Definition: correlator_plugin.h:622
void(AP_PLUGIN_CALL *setChunkValue)(const AP_PluginType *obj
Unimplemented method.
Definition: correlator_plugin.h:83
void(AP_PLUGIN_CALL *setUserData)(AP_PluginChunk *chunk
AP_bool(AP_PLUGIN_CALL *isEmpty)(const AP_PluginTypeList *list)
AP_PluginChunk *AP_PLUGIN_CALL * getChunkValue(const AP_PluginType *obj)