113 lines
3.9 KiB
C++
113 lines
3.9 KiB
C++
/**
|
|
* @file include/ActivOneApi/Test/CallbackInvokers.h
|
|
*
|
|
* @brief Header for callback invoking test helpers.
|
|
*/
|
|
|
|
#if (!defined ACTIV_ONE_API_TEST_CALLBACK_INVOKERS_H)
|
|
#define ACTIV_ONE_API_TEST_CALLBACK_INVOKERS_H
|
|
|
|
#include "ActivOneApi/External.h"
|
|
|
|
#include "ActivOneApi/TypeDefinitions.h"
|
|
|
|
//! Activ namespace.
|
|
namespace Activ
|
|
{
|
|
|
|
//! OneApi namespace.
|
|
namespace OneApi
|
|
{
|
|
|
|
class FieldListBuilder;
|
|
class ISnapshotHandler;
|
|
class ISubscriptionHandler;
|
|
class RefreshMessage;
|
|
class Session;
|
|
class SnapshotMessage;
|
|
class SnapshotFailureMessage;
|
|
class SubscriptionStatusMessage;
|
|
class TopicStatusMessage;
|
|
class UpdateMessage;
|
|
|
|
//! Test namespace.
|
|
namespace Test
|
|
{
|
|
|
|
/**
|
|
* @brief Invoke an OnSubscriptionRefresh callback.
|
|
*
|
|
* @param session the session for the callback context.
|
|
* @param handler the handler object that will receive the callback.
|
|
* @param message the message that will be provided to the callback.
|
|
* @param fieldListBuilder containing the contents of the message.
|
|
* @param pUserData the user data for the callback context.
|
|
*/
|
|
ACTIV_ONE_API void InvokeRefreshCallback(Session &session, ISubscriptionHandler &handler, RefreshMessage &message,
|
|
const FieldListBuilder &fieldListBuilder, void *pUserData = ACTIV_NULLPTR);
|
|
|
|
/**
|
|
* @brief Invoke an OnSubscriptionUpdate callback.
|
|
*
|
|
* @param session the session for the callback context.
|
|
* @param handler the handler object that will receive the callback.
|
|
* @param message the message that will be provided to the callback.
|
|
* @param fieldListBuilder containing the contents of the message.
|
|
* @param pUserData the user data for the callback context.
|
|
*/
|
|
ACTIV_ONE_API void InvokeUpdateCallback(Session &session, ISubscriptionHandler &handler, UpdateMessage &message,
|
|
const FieldListBuilder &fieldListBuilder, void *pUserData = ACTIV_NULLPTR);
|
|
|
|
/**
|
|
* @brief Invoke an OnSubscriptionStatus callback.
|
|
*
|
|
* @param session the session for the callback context.
|
|
* @param handler the handler object that will receive the callback.
|
|
* @param message the message that will be provided to the callback.
|
|
* @param pUserData the user data for the callback context.
|
|
*/
|
|
ACTIV_ONE_API void InvokeSubscriptionStatusCallback(Session &session, ISubscriptionHandler &handler,
|
|
SubscriptionStatusMessage &message, void *pUserData = ACTIV_NULLPTR);
|
|
|
|
/**
|
|
* @brief Invoke an OnSubscriptionTopicStatus callback.
|
|
*
|
|
* @param session the session for the callback context.
|
|
* @param handler the handler object that will receive the callback.
|
|
* @param message the message that will be provided to the callback.
|
|
* @param pUserData the user data for the callback context.
|
|
*/
|
|
ACTIV_ONE_API void InvokeTopicStatusCallback(Session &session, ISubscriptionHandler &handler, TopicStatusMessage &message,
|
|
void *pUserData = ACTIV_NULLPTR);
|
|
|
|
/**
|
|
* @brief Invoke an OnSnapshot callback.
|
|
*
|
|
* @param session the session for the callback context.
|
|
* @param handler the handler object that will receive the callback.
|
|
* @param message the message that will be provided to the callback.
|
|
* @param fieldListBuilder containing the contents of the message.
|
|
* @param pUserData the user data for the callback context.
|
|
*/
|
|
ACTIV_ONE_API void InvokeSnapshotCallback(Session &session, ISnapshotHandler &handler, SnapshotMessage &message,
|
|
const FieldListBuilder &fieldListBuilder, void *pUserData = ACTIV_NULLPTR);
|
|
|
|
/**
|
|
* @brief Invoke an OnSnapshotFailure callback.
|
|
*
|
|
* @param session the session for the callback context.
|
|
* @param handler the handler object that will receive the callback.
|
|
* @param message the message that will be provided to the callback.
|
|
* @param pUserData the user data for the callback context.
|
|
*/
|
|
ACTIV_ONE_API void InvokeSnapshotFailureCallback(Session &session, ISnapshotHandler &handler, SnapshotFailureMessage &message,
|
|
void *pUserData = ACTIV_NULLPTR);
|
|
|
|
} // namespace Test
|
|
|
|
} // namespace OneApi
|
|
|
|
} // namespace Activ
|
|
|
|
#endif // (!defined ACTIV_ONE_API_TEST_CALLBACK_INVOKERS_H)
|