Reuse http_network library.

Reintroduced HTTPD_STREAM_SOCKET for backward compatibility, and ease of usage.
Added websocket libraries (client, and protocol).
This commit is contained in:
2016-10-13 16:25:11 +02:00
parent 981942b2d6
commit 897f64e4fe
54 changed files with 2233 additions and 95 deletions

View File

@@ -0,0 +1,61 @@
note
description: "Summary description for {WEB_SOCKET_SUBSCRIBER}."
author: ""
date: "$Date$"
revision: "$Revision$"
deferred class
WEB_SOCKET_SUBSCRIBER
feature -- Events
on_websocket_ping (a_message: detachable STRING)
-- Send a ping in response to a received ping.
do
end
on_websocket_pong (a_message: detachable STRING)
-- Default implementation do nothing.
do
end
on_websocket_text_message (a_message: detachable STRING)
-- Default implementation do nothing.
do
end
on_websocket_binary_message (a_message: detachable STRING)
-- Default implementation do nothing.
do
end
on_websocket_open (a_message: detachable STRING)
do
end
on_websocket_close (a_message: detachable STRING)
do
end
on_websocket_error (a_error: detachable STRING)
do
end
feature -- Handshake
on_websocket_handshake (request: STRING)
-- Default do nothing
deferred
end
feature -- TCP connection
connection: HTTP_STREAM_SOCKET
deferred
end
end