123456789_123456789_123456789_123456789_123456789_

Module: Concurrent::Promises::Future::OldChannelIntegration

Relationships & Source Files
Extension / Inclusion / Inheritance Descendants
Included In:
Defined in: lib/concurrent-ruby-edge/concurrent/edge/old_channel_integration.rb

Instance Method Summary

Instance Method Details

#then_put(channel) (private)

Note:

may block

Note:

only proof of concept

[ GitHub ]

  
# File 'lib/concurrent-ruby-edge/concurrent/edge/old_channel_integration.rb', line 48

def then_put(channel)
  on_fulfillment_using(:io, channel) { |value, channel| channel.put value }
end

#then_select(*channels) ⇒ Future (private)

Zips with selected value form the suplied channels

[ GitHub ]

  
# File 'lib/concurrent-ruby-edge/concurrent/edge/old_channel_integration.rb', line 41

def then_select(*channels)
  future = Concurrent::Promises.select(*channels)
  ZipFuturesPromise.new_blocked_by2(self, future, @DefaultExecutor).future
end