|
nanoMMO 0.97.8
Building an MMO: The Engineering Series
|
#include <websocket_link.h>
Public Member Functions | |
| WebSocket (const WebSocket &)=delete | |
| WebSocket & | operator= (const WebSocket &)=delete |
| ~WebSocket () | |
| absl::Status | Send (std::string_view bytes) |
| std::string | Take () |
| What's come since the last time. | |
| bool | open () const |
| void | Wait (int milliseconds) |
Static Public Member Functions | |
| static absl::StatusOr< std::unique_ptr< WebSocket > > | Open (const std::string &url) |
A browser's WebSocket, to the gateway: the bytes it's sent, as they come, for whoever reads them. In a browser.
Definition at line 26 of file websocket_link.h.
|
delete |
| nanommo::WebSocket::~WebSocket | ( | ) |
Definition at line 57 of file websocket_link.cc.
|
static |
Opens the url, and waits for it to open, letting the page carry on meanwhile, or returns why it didn't.
Definition at line 28 of file websocket_link.cc.
|
inline |
Definition at line 42 of file websocket_link.h.
| absl::Status nanommo::WebSocket::Send | ( | std::string_view | bytes | ) |
Definition at line 62 of file websocket_link.cc.
| std::string nanommo::WebSocket::Take | ( | ) |
What's come since the last time.
Definition at line 75 of file websocket_link.cc.
| void nanommo::WebSocket::Wait | ( | int | milliseconds | ) |
Waits for something to come, or the socket to close, letting the page carry on meanwhile, for up to the milliseconds.
Definition at line 77 of file websocket_link.cc.