| | |
| | | #define NET_MODE_REQUEST_HEAD_LENGTH 16 |
| | | #define NET_MODE_RESPONSE_HEAD_LENGTH 4 |
| | | |
| | | class NetModServerSocket; |
| | | |
| | | struct net_node_t |
| | | { |
| | | const char *host; |
| | |
| | | }; |
| | | |
| | | class NetModSocket { |
| | | |
| | | friend class NetModServerSocket; |
| | | private: |
| | | static std::map<std::string, rio_t *> connectionMap; |
| | | static std::map<std::string, int> connectionMap; |
| | | ShmModSocket shmModSocket; |
| | | |
| | | |
| | |
| | | |
| | | static void * encode_response_head(net_mod_response_head_t & response); |
| | | static net_mod_response_head_t decode_response_head(void *_headbs); |
| | | |
| | | |
| | | int connect(const char *host, int port); |
| | | void remove_connect(const char *host, int port); |
| | | |
| | | public: |
| | | |
| | | NetModSocket(); |