Sha256: 40bf6ffe62e33c849bb062320f4c36211e9fbbb89ab5a92ac67848a024777684
Contents?: true
Size: 256 Bytes
Versions: 2
Compression:
Stored size: 256 Bytes
Contents
# frozen_string_literal: true module Mcoin # :nodoc: class Parallel class << self def map(array, method) array.map do |item| Thread.new { item.send(method) } end.map(&:join).map(&:value) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
mcoin-0.2.1 | lib/mcoin/parallel.rb |
mcoin-0.2.0 | lib/mcoin/parallel.rb |