Class: Protocol::HTTP::Middleware
- Defined in:
- lib/protocol/http/middleware.rb,
lib/protocol/http/middleware/builder.rb
Direct Known Subclasses
Defined Under Namespace
Modules: HelloWorld, NotFound, Okay Classes: Builder
Constant Summary
Constants inherited from Methods
Protocol::HTTP::Methods::CONNECT, Protocol::HTTP::Methods::DELETE, Protocol::HTTP::Methods::GET, Protocol::HTTP::Methods::HEAD, Protocol::HTTP::Methods::LINK, Protocol::HTTP::Methods::OPTIONS, Protocol::HTTP::Methods::PATCH, Protocol::HTTP::Methods::POST, Protocol::HTTP::Methods::PUT, Protocol::HTTP::Methods::TRACE, Protocol::HTTP::Methods::UNLINK
Instance Attribute Summary collapse
-
#delegate ⇒ Object
readonly
Returns the value of attribute delegate.
Class Method Summary collapse
Instance Method Summary collapse
- #call(request) ⇒ Object
- #close ⇒ Object
-
#initialize(delegate) ⇒ Middleware
constructor
A new instance of Middleware.
Methods inherited from Methods
Constructor Details
#initialize(delegate) ⇒ Middleware
Returns a new instance of Middleware.
29 30 31 |
# File 'lib/protocol/http/middleware.rb', line 29 def initialize(delegate) @delegate = delegate end |
Instance Attribute Details
#delegate ⇒ Object (readonly)
Returns the value of attribute delegate.
33 34 35 |
# File 'lib/protocol/http/middleware.rb', line 33 def delegate @delegate end |
Class Method Details
Instance Method Details
#call(request) ⇒ Object
39 40 41 |
# File 'lib/protocol/http/middleware.rb', line 39 def call(request) @delegate.call(request) end |
#close ⇒ Object
35 36 37 |
# File 'lib/protocol/http/middleware.rb', line 35 def close @delegate.close end |