Added make_from_execution procedure to ease implementing various use cases.
This commit is contained in:
@@ -18,6 +18,13 @@ feature {NONE} -- Initialization
|
|||||||
response := res
|
response := res
|
||||||
end
|
end
|
||||||
|
|
||||||
|
frozen make_from_execution (a_execution: WGI_EXECUTION)
|
||||||
|
-- Create current execution from `a_execution'.
|
||||||
|
do
|
||||||
|
request := a_execution.request
|
||||||
|
response := a_execution.response
|
||||||
|
end
|
||||||
|
|
||||||
feature {WGI_EXECUTION} -- Access
|
feature {WGI_EXECUTION} -- Access
|
||||||
|
|
||||||
request: WGI_REQUEST
|
request: WGI_REQUEST
|
||||||
|
|||||||
@@ -10,7 +10,8 @@ inherit
|
|||||||
WGI_EXECUTION
|
WGI_EXECUTION
|
||||||
rename
|
rename
|
||||||
request as wgi_request,
|
request as wgi_request,
|
||||||
response as wgi_response
|
response as wgi_response,
|
||||||
|
make_from_execution as make_from_wgi_execution
|
||||||
redefine
|
redefine
|
||||||
make,
|
make,
|
||||||
execute,
|
execute,
|
||||||
@@ -23,7 +24,7 @@ inherit
|
|||||||
|
|
||||||
feature {NONE} -- Initialization
|
feature {NONE} -- Initialization
|
||||||
|
|
||||||
make (req: WGI_REQUEST; res: WGI_RESPONSE)
|
frozen make (req: WGI_REQUEST; res: WGI_RESPONSE)
|
||||||
-- Create Current execution with request `req' and response `res'.
|
-- Create Current execution with request `req' and response `res'.
|
||||||
do
|
do
|
||||||
Precursor (req, res)
|
Precursor (req, res)
|
||||||
@@ -32,6 +33,15 @@ feature {NONE} -- Initialization
|
|||||||
initialize
|
initialize
|
||||||
end
|
end
|
||||||
|
|
||||||
|
frozen make_from_execution (a_execution: WSF_EXECUTION)
|
||||||
|
-- Create current execution from `a_execution'.
|
||||||
|
do
|
||||||
|
make_from_wgi_execution (a_execution)
|
||||||
|
request := a_execution.request
|
||||||
|
response := a_execution.response
|
||||||
|
initialize
|
||||||
|
end
|
||||||
|
|
||||||
initialize
|
initialize
|
||||||
-- Initialize Current object.
|
-- Initialize Current object.
|
||||||
--| To be redefined if needed.
|
--| To be redefined if needed.
|
||||||
|
|||||||
Reference in New Issue
Block a user