diff --git a/examples/restbucksCRUD/restbucks-safe.ecf b/examples/restbucksCRUD/restbucks-safe.ecf index 6c34c629..626e87d9 100644 --- a/examples/restbucksCRUD/restbucks-safe.ecf +++ b/examples/restbucksCRUD/restbucks-safe.ecf @@ -25,6 +25,7 @@ + diff --git a/examples/restbucksCRUD/src/resource/order_handler.e b/examples/restbucksCRUD/src/resource/order_handler.e index d8f5eb84..570484ae 100644 --- a/examples/restbucksCRUD/src/resource/order_handler.e +++ b/examples/restbucksCRUD/src/resource/order_handler.e @@ -82,7 +82,6 @@ feature -- HTTP Methods do create h.make create etag_utils - h.put_status ({HTTP_STATUS_CODE}.ok) h.put_content_type_application_json if attached {JSON_VALUE} json.value (l_order) as jv then l_msg := jv.representation @@ -166,7 +165,6 @@ feature -- HTTP Methods json.add_converter(joc) create h.make - h.put_status ({HTTP_STATUS_CODE}.ok) h.put_content_type_application_json if attached req.request_time as time then h.add_header ("Date:" +time.formatted_out ("ddd,[0]dd mmm yyyy [0]hh:[0]mi:[0]ss.ff2") + " GMT") @@ -212,10 +210,9 @@ feature -- HTTP Methods h : HTTP_HEADER do create h.make - h.put_status ({HTTP_STATUS_CODE}.no_content) h.put_content_type_application_json if attached req.request_time as time then - h.put_utc_date (time) + h.put_utc_date (time) end res.set_status_code ({HTTP_STATUS_CODE}.no_content) res.put_header_text (h.string) @@ -254,7 +251,6 @@ feature -- HTTP Methods create joc.make json.add_converter(joc) - h.put_status ({HTTP_STATUS_CODE}.created) h.put_content_type_application_json if attached {JSON_VALUE} json.value (l_order) as jv then l_msg := jv.representation diff --git a/examples/restbucksCRUD/src/restbucks_server.e b/examples/restbucksCRUD/src/restbucks_server.e index a8d5a519..a8f4c422 100644 --- a/examples/restbucksCRUD/src/restbucks_server.e +++ b/examples/restbucksCRUD/src/restbucks_server.e @@ -56,7 +56,6 @@ feature -- Execution req.input.read_string (req.content_length_value.as_integer_32) end create h.make - h.put_status ({HTTP_STATUS_CODE}.method_not_allowed) h.put_content_type_text_plain l_api_doc := "%NPlease check the API%NURI:/order METHOD: POST%NURI:/order/{orderid} METHOD: GET, PUT, DELETE%N" l_description := req.request_method + req.request_uri + " is not allowed" + "%N" + l_api_doc diff --git a/library/server/wsf/router/misc/wsf_format_utility.e b/library/server/wsf/router/misc/wsf_format_utility.e index d3188c9f..1f6cd18b 100644 --- a/library/server/wsf/router/misc/wsf_format_utility.e +++ b/library/server/wsf/router/misc/wsf_format_utility.e @@ -60,6 +60,8 @@ feature -- Access feature {NONE} -- Implementation string_in_array (arr: ARRAY [STRING]; s: STRING): BOOLEAN + -- Is `s' in array `arr' ? + --| using `{STRING}.same_string (..)' local i,n: INTEGER do diff --git a/library/server/wsf/router/wsf_handler.e b/library/server/wsf/router/wsf_handler.e index 2251adb7..06063eb2 100644 --- a/library/server/wsf/router/wsf_handler.e +++ b/library/server/wsf/router/wsf_handler.e @@ -16,11 +16,6 @@ deferred class inherit ANY - WSF_HANDLER_HELPER - export - {NONE} all - end - feature -- Status report is_valid_context (req: WSF_REQUEST): BOOLEAN diff --git a/library/server/wsf_extension/license.lic b/library/server/wsf_extension/license.lic new file mode 100644 index 00000000..d4d72876 --- /dev/null +++ b/library/server/wsf_extension/license.lic @@ -0,0 +1,10 @@ +${NOTE_KEYWORD} + copyright: "2011-${YEAR}, Jocelyn Fiat, Javier Velilla, Eiffel Software and others" + license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" + source: "[ + Eiffel Software + 5949 Hollister Ave., Goleta, CA 93117 USA + Telephone 805-685-1006, Fax 805-685-6869 + Website http://www.eiffel.com + Customer support http://support.eiffel.com + ]" diff --git a/library/server/wsf/router/misc/wsf_handler_helper.e b/library/server/wsf_extension/src/wsf_handler_helper.e similarity index 100% rename from library/server/wsf/router/misc/wsf_handler_helper.e rename to library/server/wsf_extension/src/wsf_handler_helper.e diff --git a/library/server/wsf/router/misc/wsf_handler_routes_recorder.e b/library/server/wsf_extension/src/wsf_handler_routes_recorder.e similarity index 100% rename from library/server/wsf/router/misc/wsf_handler_routes_recorder.e rename to library/server/wsf_extension/src/wsf_handler_routes_recorder.e diff --git a/library/server/wsf/router/misc/wsf_resource_handler_helper.e b/library/server/wsf_extension/src/wsf_resource_handler_helper.e similarity index 100% rename from library/server/wsf/router/misc/wsf_resource_handler_helper.e rename to library/server/wsf_extension/src/wsf_resource_handler_helper.e diff --git a/library/server/wsf_extension/wsf_extension-safe.ecf b/library/server/wsf_extension/wsf_extension-safe.ecf new file mode 100644 index 00000000..8f811dc1 --- /dev/null +++ b/library/server/wsf_extension/wsf_extension-safe.ecf @@ -0,0 +1,17 @@ + + + + + + /.git$ + /EIFGENs$ + /.svn$ + + + + + + + + diff --git a/library/server/wsf_extension/wsf_extension.ecf b/library/server/wsf_extension/wsf_extension.ecf new file mode 100644 index 00000000..9f795b1e --- /dev/null +++ b/library/server/wsf_extension/wsf_extension.ecf @@ -0,0 +1,17 @@ + + + + + + /.git$ + /EIFGENs$ + /.svn$ + + + + + + + +