// // Created by huli on 2020/6/29. // #ifndef NNXX_TESTS_COMMUNICATION_MESSAGE_H #define NNXX_TESTS_COMMUNICATION_MESSAGE_H #include #include #include class Communication_message { //消息类型定义,每个在网络上传输的消息必须含有这个属性 enum Message_type { COMMAND_MESSAGE = 0X01, //指令消息 SENSING_STATUS_MESSAGE = 0X11, //定位模块状态消息 SENSING_REQUEST_MESSAGE = 0X12, //定位请求消息 SENSING_RESPONSE_MESSAGE = 0X13, //定位反馈消息 HARWARE_STATU_MESSAGE = 0X21, //调度模块硬件状态消息 EXECUTE_REQUEST_MESSAGE = 0X22, //请求调度消息 EXECUTE_RESPONSE_MESSAGE = 0X23, //调度结果反馈消息 }; public: Communication_message(); Communication_message(const Communication_message& other)= default; Communication_message& operator =(const Communication_message& other)= default; ~Communication_message(); public://API functions public://get or set member variable protected://member variable Message_type m_message_type; //消息类型 std::chrono::system_clock::time_point m_receive_time; //接收时间 private: }; #endif //NNXX_TESTS_COMMUNICATION_MESSAGE_H