123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101 |
- #pragma once
- #include <string>
- #include "DIOS.Dev.IODevice.hpp"
- #include "DIOS.Dev.IODevice.Detail.hpp"
- #include "DAP.BasicMoulds.hpp"
- #include "DriverConfigInfo.tlh"
- #include "DriverConfigInfo.tli"
- namespace nsDetail = DIOS::Dev::Detail;
- #ifndef DIOSDEVDAPDEVICEMOULD_EXPORTS
- #ifdef _WIN64
- #ifdef _DEBUG
- #pragma comment(lib, "DIOS.Dev.DAP.Mould64D.lib")
- #else
- #pragma comment(lib, "DIOS.Dev.DAP.Mould64.lib")
- #endif
- #else
- #ifdef _DEBUG
- #pragma comment(lib, "DIOS.Dev.DAP.MouldD.lib")
- #else
- #pragma comment(lib, "DIOS.Dev.DAP.MouldD.lib")
- #endif
- #endif
- #endif
- #ifdef DIOSDEVDAPDEVICEMOULD_EXPORTS
- #define _DIOSDEVDAPDEVICEMOULD_API __declspec(dllexport)
- #else
- #define _DIOSDEVDAPDEVICEMOULD_API __declspec(dllimport)
- #endif
- #pragma warning (disable:4251) // warning C4251: class “DIOS::Dev::Detail::Generator::DoseUnit”需要有 dll 接口由 class“DIOS::Dev::Detail::Generator::DAPMould”的客户端使用
- namespace DIOS::Dev::Detail::DAP
- {
- //-----------------------------------------------------------------------------
- // DAPUnit
- //-----------------------------------------------------------------------------
- class _DIOSDEVDAPDEVICEMOULD_API DAPUnit : public IOLogicUnit
- {
- public:
- DAPUnit() {};
- virtual ~DAPUnit() {};
- public:
- std::unique_ptr<DOSEMould> m_DAP;
- };
- //-----------------------------------------------------------------------------
- // DAPMould
- //-----------------------------------------------------------------------------
- namespace nDev = DIOS::Dev;
- class _DIOSDEVDAPDEVICEMOULD_API DAPMould
- {
- public:
- DAPMould ();
- ~DAPMould ();
- protected:
- virtual void Register(Dispatch* Dispatch);
- private:
- //caoxue
- nDev::RET_STATUS JSGetDAP (std::string& out);
- nDev::RET_STATUS JSResetDAP (std::string in, std::string& out);
- nDev::RET_STATUS JSObtainDAP(std::string in, std::string& out);
- protected:
- virtual float GetDAP();
- virtual nDev::RET_STATUS ClearDAP() = 0;
- virtual nDev::RET_STATUS QueryDAP(float& value) = 0;
- protected:
- DAPUnit m_DAPUnit;
- };
- }
- namespace DIOS::Dev::Detail::DAP
- {
- class _DIOSDEVDAPDEVICEMOULD_API DriverMould : public DIOS::Dev::IODriver
- {
- public:
- DriverMould ();
- ~DriverMould ();
- virtual std::string GetGUID () const;
- protected:
- std::list <ConfigInfo> m_ConfigInfo;
- };
- }
|