Class: HttpStub::Server::ResponsePipeline
- Inherits:
-
Object
- Object
- HttpStub::Server::ResponsePipeline
- Defined in:
- lib/http_stub/server/response_pipeline.rb
Instance Method Summary collapse
-
#initialize(server) ⇒ ResponsePipeline
constructor
A new instance of ResponsePipeline.
- #process(response) ⇒ Object
Constructor Details
#initialize(server) ⇒ ResponsePipeline
Returns a new instance of ResponsePipeline.
6 7 8 |
# File 'lib/http_stub/server/response_pipeline.rb', line 6 def initialize(server) @server = server end |
Instance Method Details
#process(response) ⇒ Object
10 11 12 13 |
# File 'lib/http_stub/server/response_pipeline.rb', line 10 def process(response) sleep response.delay_in_seconds response.serve_on(@server) end |