class Array

Public Instance Methods

each_in_parallel(&block) click to toggle source
# File lib/armada/utils/array.rb, line 2
def each_in_parallel(&block)
  threads = map do |s|
    Thread.new { block.call(s) }
  end

  threads.each { |t| t.join }
end