From 90ae1c3db92833354814484e65f8cd2eef1f5f3e Mon Sep 17 00:00:00 2001
From: LAPTOP-SNT8I5JK\Boounion <Chenluhua@qq.com>
Date: 星期三, 30 七月 2025 15:14:20 +0800
Subject: [PATCH] 1.配方列表获取完善;

---
 SourceCode/Bond/HSMSSDK/Include/IActive.h |   41 +++++++++++++++++++++++++++++++++++++++++
 1 files changed, 41 insertions(+), 0 deletions(-)

diff --git a/SourceCode/Bond/HSMSSDK/Include/IActive.h b/SourceCode/Bond/HSMSSDK/Include/IActive.h
new file mode 100644
index 0000000..ce2f9e7
--- /dev/null
+++ b/SourceCode/Bond/HSMSSDK/Include/IActive.h
@@ -0,0 +1,41 @@
+#pragma once
+#include <functional>
+#include "IMessage.h"
+
+
+enum class ACTIVESTATE
+{
+	NOT_CONNECTED = 0,
+	NOT_SELECTED = 1,
+	SELECTED = 2
+};
+
+typedef std::function<void(void* pFrom, ACTIVESTATE state)> ONACTIVESTATECHANGED;
+typedef std::function<void(void* pFrom, const char* pszData, int size)> ONRECVRAWDATA;
+typedef std::function<void(void* pFrom, IMessage* pMessage)> ONRECVDATAMSG;
+typedef std::function<void(void* pFrom, IMessage* pMessage)> ONRECVSYSMSG;
+typedef std::function<void(void* pFrom, int error)> ONDATAERROR;
+typedef struct _ActiveListener
+{
+	ONACTIVESTATECHANGED	funStateChanged;
+	ONRECVRAWDATA			funRecvRawData;
+	ONRECVDATAMSG			funRecvDataMessage;
+	ONRECVSYSMSG			funRecvSysMessage;
+	ONDATAERROR				funError;
+} ActiveListener;
+
+
+class IActive
+{
+public:
+	virtual void setListener(ActiveListener listener) = 0;
+	virtual void setTimeout3(int timeout) = 0;
+	virtual void setTimeout5(int timeout) = 0;
+	virtual void setTimeout6(int timeout) = 0;
+	virtual void setTimeout7(int timeout) = 0;
+	virtual void setTimeout8(int timeout) = 0;
+	virtual int sendMessage(IMessage* pMessage) = 0;
+	virtual ACTIVESTATE getState() = 0;
+	virtual int connect() = 0;
+	virtual int disconnect() = 0;
+};

--
Gitblit v1.9.3