Updated deprecated EiffelWeb nino to make it compilable with upcoming EiffelStudio 16.11.

Updated various projects to make them up-to-date and compilable with this latest EiffelWeb.
This commit is contained in:
2016-10-10 21:40:15 +02:00
parent aed7461faf
commit 7a546622bc
9 changed files with 70 additions and 70 deletions

View File

@@ -38,7 +38,7 @@ feature {NONE} -- Initialization
make_with_base (a_base: detachable separate READABLE_STRING_8)
-- Create current standalone connector with base url `a_base'
require
a_base_starts_with_slash: a_base /= Void implies is_valid_base (a_base)
a_base_starts_with_slash: (a_base /= Void and then not a_base.is_empty) implies is_valid_base (a_base)
do
make
set_base (a_base)
@@ -181,6 +181,13 @@ feature -- Element change
feature -- Server
launch_on_port (a_port_number: INTEGER)
-- Launch server listening on port `a_port_number'.
do
set_port_number (a_port_number)
launch
end
launch
-- Launch web server listening.
do

View File

@@ -15,13 +15,13 @@ feature {NONE} -- Initialization
make
do
print ("Example: start a Standalone web server on port " + port_number.out + ", %Nand reply Hello World for any request such as http://localhost:8123/%N")
(create {STANDALONE_SERVICE [HELLO_WORLD_EXECUTION]}.make_custom ("")).listen (port_number)
(create {WGI_STANDALONE_CONNECTOR [HELLO_WORLD_EXECUTION]}.make_with_base ("")).launch_on_port (port_number)
end
port_number: INTEGER = 8123
note
copyright: "2011-2015, Eiffel Software and others"
copyright: "2011-2016, Eiffel Software and others"
license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)"
source: "[
Eiffel Software

View File

@@ -18,12 +18,12 @@ feature {NONE} -- Initialization
execute
do
response.set_status_code (200, Void)
response.put_header_text ("Content-Type: text/plain%R%N")
response.put_header_text ("Content-Length: 13%R%NContent-Type: text/plain%R%N")
response.put_string ("Hello World!%N")
end
note
copyright: "2011-2015, Eiffel Software and others"
copyright: "2011-2016, Eiffel Software and others"
license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)"
source: "[
Eiffel Software