Module: Laboratory::Algorithms

Defined in:
lib/laboratory/algorithms.rb,
lib/laboratory/algorithms/random.rb

Defined Under Namespace

Classes: Random

Constant Summary collapse

ALGORITHMS =
[
  Laboratory::Algorithms::Random
].freeze

Class Method Summary collapse

Class Method Details

.to_class(algorithm_id) ⇒ Object



7
8
9
# File 'lib/laboratory/algorithms.rb', line 7

def self.to_class(algorithm_id)
  ALGORITHMS.find { |algorithm_class| algorithm_class.id == algorithm_id }
end