Class: Sink::InputRejectWrapper

Inherits:
InputWrapper show all
Defined in:
lib/coroutines/sink.rb

Instance Method Summary collapse

Methods inherited from InputWrapper

#close, #initialize

Methods included from Sink

#<=, #close, #input_map, #input_reduce, #input_reject, #input_select

Constructor Details

This class inherits a constructor from Sink::InputWrapper

Instance Method Details

#<<(args) ⇒ Object



122
123
124
# File 'lib/coroutines/sink.rb', line 122

def <<(args)
  @target << args unless @block.call(args)
end

#inspectObject



125
126
127
# File 'lib/coroutines/sink.rb', line 125

def inspect
  "#<#{@target.inspect}#reject>"
end