mirror of
https://github.com/g4klx/MMDVMHost.git
synced 2026-04-06 15:04:18 +00:00
Make the remote command handler more flexible and add an optional
timeout to the new mode.
This commit is contained in:
parent
8ae8894d6f
commit
b57d42327a
3 changed files with 145 additions and 29 deletions
|
|
@ -21,6 +21,9 @@
|
|||
|
||||
#include "UDPSocket.h"
|
||||
|
||||
#include <vector>
|
||||
#include <string>
|
||||
|
||||
enum REMOTE_COMMAND {
|
||||
RCD_NONE,
|
||||
RCD_MODE_IDLE,
|
||||
|
|
@ -41,10 +44,18 @@ public:
|
|||
|
||||
REMOTE_COMMAND getCommand();
|
||||
|
||||
unsigned int getArgCount() const;
|
||||
|
||||
std::string getArgString(unsigned int n) const;
|
||||
unsigned int getArgUInt(unsigned int n) const;
|
||||
signed int getArgInt(unsigned int n) const;
|
||||
|
||||
void close();
|
||||
|
||||
private:
|
||||
CUDPSocket m_socket;
|
||||
CUDPSocket m_socket;
|
||||
REMOTE_COMMAND m_command;
|
||||
std::vector<std::string> m_args;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue