Added websocket examples for the server and client.

This commit is contained in:
2016-10-13 22:01:50 +02:00
parent 1e4203111f
commit 01a9d02586
18 changed files with 10562 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
note
description: "Summary description for {WEB_SOCKET_EXECUTION}."
date: "$Date$"
revision: "$Revision$"
deferred class
WEB_SOCKET_EXECUTION
inherit
WSF_WEBSOCKET_EXECUTION
WEB_SOCKET_EVENT_I
feature -- Websocket execution
new_websocket_handler (ws: WEB_SOCKET): WEB_SOCKET_HANDLER
do
create Result.make (ws, Current)
end
end

View File

@@ -0,0 +1,30 @@
note
description: "Summary description for {WEB_SOCKET_SERVICE}."
date: "$Date$"
revision: "$Revision$"
class
WEB_SOCKET_SERVICE [G -> WEB_SOCKET_EXECUTION create make end]
create
make_and_launch
feature {NONE} -- Initialization
make_and_launch
local
l_launcher: WSF_STANDALONE_WEBSOCKET_SERVICE_LAUNCHER [G]
opts: WEB_SOCKET_SERVICE_OPTIONS
do
create opts
set_options (opts)
opts.append_options (create {WSF_SERVICE_LAUNCHER_OPTIONS_FROM_INI}.make_from_file ("ws.ini"))
create l_launcher.make_and_launch (opts)
end
set_options (opts: WEB_SOCKET_SERVICE_OPTIONS)
-- Set values on `opts'.
do
end
end

View File

@@ -0,0 +1,12 @@
note
description: "Summary description for {WEB_SOCKET_SERVICE_OPTIONS}."
date: "$Date$"
revision: "$Revision$"
class
WEB_SOCKET_SERVICE_OPTIONS
inherit
WSF_STANDALONE_WEBSOCKET_SERVICE_OPTIONS
end