Class: Zizq::Middleware::Link
- Inherits:
-
Object
- Object
- Zizq::Middleware::Link
- Defined in:
- lib/zizq/middleware.rb,
sig/generated/zizq/middleware.rbs
Overview
A single link in the middleware chain, connecting a middleware to the next link (or terminal).
Instance Method Summary collapse
-
#call(arg) ⇒ Object
Invoke this middleware, passing the next link for continuation.
-
#initialize(middleware, next_link) ⇒ Link
constructor
A new instance of Link.
Constructor Details
#initialize(middleware, next_link) ⇒ Link
Returns a new instance of Link.
69 70 71 72 |
# File 'lib/zizq/middleware.rb', line 69 def initialize(middleware, next_link) #: (untyped, untyped) -> void @middleware = middleware @next_link = next_link end |
Instance Method Details
#call(arg) ⇒ Object
Invoke this middleware, passing the next link for continuation.
75 76 77 |
# File 'lib/zizq/middleware.rb', line 75 def call(arg) #: (untyped) -> untyped @middleware.call(arg, @next_link) end |