Starting revival of debugger system. Work on #41.
This commit is contained in:
62
src/xenia/debug/protocols/ws/ws_client.h
Normal file
62
src/xenia/debug/protocols/ws/ws_client.h
Normal file
@@ -0,0 +1,62 @@
|
||||
/**
|
||||
******************************************************************************
|
||||
* Xenia : Xbox 360 Emulator Research Project *
|
||||
******************************************************************************
|
||||
* Copyright 2013 Ben Vanik. All rights reserved. *
|
||||
* Released under the BSD license - see LICENSE in the root for more details. *
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#ifndef XENIA_DEBUG_PROTOCOLS_WS_WS_CLIENT_H_
|
||||
#define XENIA_DEBUG_PROTOCOLS_WS_WS_CLIENT_H_
|
||||
|
||||
#include <xenia/common.h>
|
||||
#include <xenia/core.h>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <xenia/debug/debug_client.h>
|
||||
|
||||
|
||||
struct wslay_event_msg;
|
||||
|
||||
|
||||
namespace xe {
|
||||
namespace debug {
|
||||
namespace protocols {
|
||||
namespace ws {
|
||||
|
||||
|
||||
class WSClient : public DebugClient {
|
||||
public:
|
||||
WSClient(DebugServer* debug_server, int socket_id);
|
||||
virtual ~WSClient();
|
||||
|
||||
socket_t socket_id();
|
||||
|
||||
virtual int Setup();
|
||||
|
||||
void Write(uint8_t** buffers, size_t* lengths, size_t count);
|
||||
|
||||
private:
|
||||
static void StartCallback(void* param);
|
||||
|
||||
int PerformHandshake();
|
||||
void EventThread();
|
||||
|
||||
xe_thread_ref thread_;
|
||||
|
||||
socket_t socket_id_;
|
||||
xe_socket_loop_t* loop_;
|
||||
xe_mutex_t* mutex_;
|
||||
std::vector<struct wslay_event_msg> pending_messages_;
|
||||
};
|
||||
|
||||
|
||||
} // namespace ws
|
||||
} // namespace protocols
|
||||
} // namespace debug
|
||||
} // namespace xe
|
||||
|
||||
|
||||
#endif // XENIA_DEBUG_PROTOCOLS_WS_WS_CLIENT_H_
|
||||
Reference in New Issue
Block a user