12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182 |
- #pragma once
- #include <string>
- #include <list>
- enum ModuleType
- {
- Sensor=1,
- Actor=2,
- Purifier=3,
- Calculator=4,
- Storage=5,
- Transfer=6,
- };
- struct DataItem
- {
- int Id;
- std::string DataName;
- std::string Code;
- std::string DataType;
- bool Displayed;
- std::string Description;
- std::string ToString()
- {
- return Code + DataName;
- }
- };
- struct ModuleInfo
- {
- int Id;
- ModuleType Type; // 类型
- std::string Name; // 名称
- std::string Code; // 标识码
- std::string Model; // 型号
- std::string AssemblyName; // 组件程序(dll、jar)名字,含路径
- std::string ClassName; // 组件的 类名
- std::string Description; // 描述
- std::string Version; // 版本
- };
- struct DeviceInfo
- {
- int Id;
- std::string Name; // 名称
- std::string Type; // 类型
- std::string Code; // 标识码
- std::string Model; // 型号,通信组件的Code属性
- int ServerId; //
- ModuleInfo ModuleInfo; //
- std::string Description; // 描述
- std::list<DataItem> Properties;
- };
- struct ConsumerInfo{
- std::string name;
- std::string AssemblyName; // 组件程序(dll、jar)名字,含路径
- std::string ClassName; // 组件的 类名
- std::string SubscribeName;
- };
- struct DataManagerInfo{
- int Id;
- std::string Name; // 名称
- std::string Type; // 类型
- std::string Code; // 标识码
- std::string Model; // 型号,通信组件的Code属性
- int ServerId; //
- std::string Description; // 描述
- std::list<ModuleInfo> modules;
- std::list<ConsumerInfo>consumers;
- };
- struct Config
- {
- int serverId;
- std::string appName;
- };
|