🛰️航天仿真算法库 SpaceAST 0.0.1
载入中...
搜索中...
未找到
PilotPipeServer.hpp
浏览该文件的文档.
1
19
20#pragma once
21
22#include "AstGlobal.h"
23#include <string>
24#include <atomic>
25#include <thread>
26
27AST_NAMESPACE_BEGIN
28
29class PilotCommander;
30
40class AST_UIPILOT_API PilotPipeServer
41{
42public:
46 explicit PilotPipeServer(PilotCommander* commander, unsigned long pid);
47
50
52 void start();
53
55 void stop();
56
58 bool isRunning() const { return running_; }
59
61 static std::string pipeName(unsigned long pid);
62
63private:
65 void serverLoop();
66
67 PilotCommander* commander_;
68 unsigned long pid_;
69 std::atomic<bool> running_{false};
70 std::thread serverThread_;
71};
72
75AST_NAMESPACE_END
命令调度器
定义 PilotCommander.hpp:44
Named Pipe 服务端
定义 PilotPipeServer.hpp:41
bool isRunning() const
是否正在运行
定义 PilotPipeServer.hpp:58