Top Level Namespace
Defined Under Namespace
Modules: Enumerable Classes: ParallelException
Instance Method Summary collapse
-
#parallelize(num_threads, collect_exceptions = false, &block) ⇒ Array
Execute the given block with multiple threads.
Instance Method Details
#parallelize(num_threads, collect_exceptions = false, &block) ⇒ Array
Execute the given block with multiple threads.
8 9 10 |
# File 'lib/parallelize.rb', line 8 def parallelize num_threads, collect_exceptions = false, &block num_threads.times.peach(num_threads, collect_exceptions, &block) end |