Fixed signature of `set_next' to allow redefinition.

Added assertions
This commit is contained in:
Jocelyn Fiat
2013-03-21 15:47:52 +01:00
parent 1f76fd5360
commit 62d880a7c1

View File

@@ -14,7 +14,7 @@ feature -- Access
feature -- Element change feature -- Element change
set_next (a_next: WSF_FILTER) set_next (a_next: like next)
-- Set `next' to `a_next' -- Set `next' to `a_next'
do do
next := a_next next := a_next
@@ -26,6 +26,9 @@ feature -- Basic operations
execute (req: WSF_REQUEST; res: WSF_RESPONSE) execute (req: WSF_REQUEST; res: WSF_RESPONSE)
-- Execute the filter. -- Execute the filter.
require
req_attached: req /= Void
res_attached: res /= Void
deferred deferred
end end
@@ -33,6 +36,9 @@ feature {NONE} -- Implementation
execute_next (req: WSF_REQUEST; res: WSF_RESPONSE) execute_next (req: WSF_REQUEST; res: WSF_RESPONSE)
-- Execute the `next' filter. -- Execute the `next' filter.
require
req_attached: req /= Void
res_attached: res /= Void
do do
if attached next as n then if attached next as n then
n.execute (req, res) n.execute (req, res)
@@ -40,7 +46,7 @@ feature {NONE} -- Implementation
end end
note note
copyright: "2011-2012, Jocelyn Fiat, Javier Velilla, Olivier Ligot, Eiffel Software and others" copyright: "2011-2013, Jocelyn Fiat, Javier Velilla, Olivier Ligot, Eiffel Software and others"
license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)"
source: "[ source: "[
Eiffel Software Eiffel Software