Files
2026-08-24 10:03:24 +08:00

40 lines
1.1 KiB
C++

#ifndef DTVKITINTERFACE_H
#define DTVKITINTERFACE_H
#include <iostream>
#include <sstream>
#include <string>
/**
* @brief Notify that DTVKIT module async event
* @param signal : message name
* @param data : message content
* @return n/a
*/
typedef void (*EventHandler)(const std::string &signal, const std::string &data);
/**
* @brief DTVKIT module init
* @param reference :DTVKIT JS UI Integration User Guide .pdf
* @return n/a
*/
int Dtvkit_init(void);
/**
* @brief register dtvkit module callback function
* @param EventHandler : callback function
* @return n/a
*/
void registerEventHandler(EventHandler handler);
/**
* @brief to dtvkit module sync call function
* @param params: reference: DTVKIT JS UI Integration User Guide .pdf
* @return n/a
*/
std::string request_interface(const std::string& params);
std::string request(const std::string& resource, const std::string& json);
/**
* @brief used by WPEDTVKIT pack callback message to json format
*/
std::string PackCallbackMessage(const std::string &signal, const std::string &data);
#endif //DTVKITINTERFACE_H