From 03b10bdc140350bfaa851e4b9c426e63f7acb458 Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Fri, 16 Mar 2012 13:35:52 +0100 Subject: [PATCH] Removed HTTP_HEADER.put_status (...) It is not recommended to send the status code as part of the HTTP Header, so let's remove this ambiguity and do not encourage EWF user to use it --- library/protocol/http/src/http_header.e | 26 ++----------------------- 1 file changed, 2 insertions(+), 24 deletions(-) diff --git a/library/protocol/http/src/http_header.e b/library/protocol/http/src/http_header.e index 19895286..6cb1a892 100644 --- a/library/protocol/http/src/http_header.e +++ b/library/protocol/http/src/http_header.e @@ -12,7 +12,6 @@ note (or HTTP_CONSTANTS which groups them for convenience) Note the return status code is not part of the HTTP header - However you can set the "Status: " header line if you want ]" legal: "See notice at end of class." status: "See notice at end of class." @@ -25,11 +24,6 @@ class inherit ANY - HTTP_STATUS_CODE_MESSAGES --| useful for `put_status' - export - {NONE} all - end - create make, make_with_count, @@ -128,7 +122,7 @@ feature -- Header: filling loop add_header (c.item.string) end - end + end feature -- Header change: general @@ -162,22 +156,6 @@ feature -- Header change: general put_header (k + colon_space + v) end -feature -- Status related - - put_status (c: INTEGER) - -- Put "Status: " header - -- Rarely used - local - s: STRING - do - create s.make_from_string (c.out) - if attached http_status_code_message (c) as msg then - s.append_character (' ') - s.append (msg) - end - put_header_key_value ("Status", s) - end - feature -- Content related header put_content_type (t: READABLE_STRING_8) @@ -581,7 +559,7 @@ feature {NONE} -- Constants semi_colon_space: STRING = "; " note - copyright: "2011-2012, Eiffel Software and others" + copyright: "2011-2012, Jocelyn Fiat, Eiffel Software and others" license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" source: "[ Eiffel Software