/device/google/cuttlefish/host/libs/websocket/ |
D | websocket_server.cpp | 31 std::string GetPath(struct lws* wsi) { in GetPath() argument 32 auto len = lws_hdr_total_length(wsi, WSI_TOKEN_GET_URI); in GetPath() 34 auto ret = lws_hdr_copy(wsi, path.data(), path.size(), WSI_TOKEN_GET_URI); in GetPath() 36 len = lws_hdr_total_length(wsi, WSI_TOKEN_HTTP_COLON_PATH); in GetPath() 39 lws_hdr_copy(wsi, path.data(), path.size(), WSI_TOKEN_HTTP_COLON_PATH); in GetPath() 55 bool AddCORSHeaders(struct lws* wsi, unsigned char** buffer_ptr, in AddCORSHeaders() argument 61 wsi, reinterpret_cast<const unsigned char*>(name.c_str()), in AddCORSHeaders() 71 size_t content_len, struct lws* wsi) { in WriteCommonHttpHeaders() argument 77 if (lws_add_http_common_headers(wsi, status, mime_type, content_len, &p, in WriteCommonHttpHeaders() 82 if (!AddCORSHeaders(wsi, &p, end)) { in WriteCommonHttpHeaders() [all …]
|
D | websocket_server.h | 53 static int WebsocketCallback(struct lws* wsi, 57 static int DynHttpCallback(struct lws* wsi, enum lws_callback_reasons reason, 60 int ServerCallback(struct lws* wsi, enum lws_callback_reasons reason, 62 int DynServerCallback(struct lws* wsi, 66 const std::string& uri_path, struct lws* wsi); 68 const std::string& uri_path, struct lws* wsi);
|
D | websocket_handler.cpp | 33 WebSocketHandler::WebSocketHandler(struct lws* wsi) : wsi_(wsi) {} in WebSocketHandler() argument 82 DynHandler::DynHandler(struct lws* wsi) : wsi_(wsi), out_buffer_(LWS_PRE, 0) {} in DynHandler() argument
|
D | websocket_handler.h | 28 WebSocketHandler(struct lws* wsi); 64 virtual std::shared_ptr<WebSocketHandler> Build(struct lws* wsi) = 0; 82 DynHandler(struct lws* wsi);
|
/device/google/cuttlefish/host/frontend/webrtc_operator/ |
D | server.cpp | 70 kListDevicesUriPath, [&device_registry](struct lws* wsi) { in main() argument 72 new cuttlefish::DeviceListHandler(wsi, device_registry)); in main() 91 kInfraConfigPath, [&server_config](struct lws* wsi) { in main() argument 93 new cuttlefish::ConfigHandler(wsi, server_config)); in main() 96 kConnectPath, [&device_registry, &poll_store](struct lws* wsi) { in main() argument 98 new cuttlefish::ConnectHandler(wsi, &device_registry, &poll_store)); in main() 101 kForwardPath, [&poll_store](struct lws* wsi) { in main() argument 103 new cuttlefish::ForwardHandler(wsi, &poll_store)); in main() 106 kPollPath, [&poll_store](struct lws* wsi) { in main() argument 108 new cuttlefish::PollHandler(wsi, &poll_store)); in main()
|
D | client_handler.cpp | 43 ClientWSHandler::ClientWSHandler(struct lws* wsi, DeviceRegistry* registry, in ClientWSHandler() argument 45 : SignalHandler(wsi, registry, server_config), in ClientWSHandler() 138 std::shared_ptr<WebSocketHandler> ClientWSHandlerFactory::Build(struct lws* wsi) { in Build() argument 140 new ClientWSHandler(wsi, registry_, server_config_)); in Build() 200 ClientDynHandler::ClientDynHandler(struct lws* wsi, in ClientDynHandler() argument 202 : DynHandler(wsi), poll_store_(poll_store) {} in ClientDynHandler() 268 ConnectHandler::ConnectHandler(struct lws* wsi, DeviceRegistry* registry, in ConnectHandler() argument 270 : ClientDynHandler(wsi, poll_store), registry_(registry) {} in ConnectHandler() 304 ForwardHandler::ForwardHandler(struct lws* wsi, in ForwardHandler() argument 306 : ClientDynHandler(wsi, poll_store) {} in ForwardHandler() [all …]
|
D | client_handler.h | 41 ClientWSHandler(struct lws* wsi, DeviceRegistry* registry, 66 std::shared_ptr<WebSocketHandler> Build(struct lws* wsi) override; 89 ClientDynHandler(struct lws* wsi, PollConnectionStore* poll_store); 109 ConnectHandler(struct lws* wsi, DeviceRegistry* registry, 121 ForwardHandler(struct lws* wsi, PollConnectionStore* poll_store); 130 PollHandler(struct lws* wsi, PollConnectionStore* poll_store); 139 ConfigHandler(struct lws* wsi, const ServerConfig& server_config);
|
D | device_handler.cpp | 25 DeviceHandler::DeviceHandler(struct lws* wsi, DeviceRegistry* registry, in DeviceHandler() argument 27 : SignalHandler(wsi, registry, server_config), device_info_(), clients_() {} in DeviceHandler() 127 std::shared_ptr<WebSocketHandler> DeviceHandlerFactory::Build(struct lws* wsi) { in Build() argument 129 new DeviceHandler(wsi, registry_, server_config_)); in Build()
|
D | device_list_handler.cpp | 20 DeviceListHandler::DeviceListHandler(struct lws* wsi, in DeviceListHandler() argument 22 : DynHandler(wsi), registry_(registry) {} in DeviceListHandler()
|
D | device_handler.h | 36 DeviceHandler(struct lws* wsi, DeviceRegistry* registry, 64 std::shared_ptr<WebSocketHandler> Build(struct lws* wsi) override;
|
D | signal_handler.cpp | 25 SignalHandler::SignalHandler(struct lws* wsi, DeviceRegistry* registry, in SignalHandler() argument 27 : WebSocketHandler(wsi), in SignalHandler()
|
D | device_list_handler.h | 30 DeviceListHandler(struct lws* wsi, DeviceRegistry& registry);
|
D | signal_handler.h | 36 SignalHandler(struct lws* wsi, DeviceRegistry* registry,
|
/device/google/cuttlefish/host/frontend/webrtc/libdevice/ |
D | server_connection.cpp | 296 int LwsCallback(struct lws* wsi, enum lws_callback_reasons reason, void* user, 500 int LwsCallback(struct lws* wsi, enum lws_callback_reasons reason, void* user, in LwsCallback() argument 509 [wsi, user](std::function<void(std::shared_ptr<WsConnection>)> cb) { in LwsCallback() 511 auto connection = context->GetConnection(wsi); in LwsCallback() 527 [in, len, wsi](std::shared_ptr<WsConnection> connection) { in LwsCallback() 529 lws_frame_is_binary(wsi)); in LwsCallback() 549 return lws_callback_http_dummy(wsi, reason, user, in, len); in LwsCallback()
|