Class: Pyper::Pipes::Tap
- Inherits:
-
Object
- Object
- Pyper::Pipes::Tap
- Defined in:
- lib/pyper/pipes/tap.rb
Instance Method Summary collapse
- #call(arg, _status) ⇒ Object
-
#initialize(&block) ⇒ Tap
constructor
A new instance of Tap.
Constructor Details
#initialize(&block) ⇒ Tap
Returns a new instance of Tap.
3 4 5 |
# File 'lib/pyper/pipes/tap.rb', line 3 def initialize(&block) @block = block end |
Instance Method Details
#call(arg, _status) ⇒ Object
7 8 9 |
# File 'lib/pyper/pipes/tap.rb', line 7 def call(arg, _status) arg.tap(&@block) end |