lib/ripe/worker_controller.rb
def distribute(workers, &block)
      workers = [workers] if workers.is_a? DB::Worker
      workers.map do |w|
        block.call(w)
        w
      end
    end
##
# Apply a block to a list of workers.
#
# @param workers [Array<DB::Worker>, DB::Worker] a list of workers or a
#   single worker
# @return [Array<DB::Worker>] the list of workers given in arguments,
#   with modified states
Apply a block to a list of workers.
Apply a block to a list of workers .
def distribute(workers, &block)
      workers = [workers] if workers.is_a? DB::Worker
      workers.map do |w|
        block.call(w)
        w
      end
    end
def distribute ( workers , & block ) workers = [ workers ] if workers . is_a? DB :: Worker workers . map do | w | block . call ( w ) w end end
Apply a block to a list of workers.
Apply a block to a list of workers .
the list of workers given in arguments, with modified states
the list of workers given in arguments with modified states
Array<DB::Worker>
workers
a list of workers or a single worker
a list of workers or a single worker
block