Module: ViennaRna::Package

Defined in:
lib/vienna_rna.rb,
lib/vienna_rna/package/base.rb,
lib/vienna_rna/package/eval.rb,
lib/vienna_rna/package/fold.rb,
lib/vienna_rna/package/heat.rb,
lib/vienna_rna/package/mfpt.rb,
lib/vienna_rna/package/plot.rb,
lib/vienna_rna/package/xbor.rb,
lib/vienna_rna/package/fftbor.rb,
lib/vienna_rna/package/rnabor.rb,
lib/vienna_rna/package/subopt.rb,
lib/vienna_rna/package/fft_mfpt.rb,
lib/vienna_rna/package/fftbor2d.rb,
lib/vienna_rna/package/spectral.rb,
lib/vienna_rna/package/kinwalker.rb,
lib/vienna_rna/package/rna2dfold.rb,
lib/vienna_rna/package/tabu_path.rb,
lib/vienna_rna/package/ffthairpin.rb,
lib/vienna_rna/package/population.rb,
lib/vienna_rna/package/fftmultiloop.rb,
lib/vienna_rna/package/energy_grid_2d.rb

Defined Under Namespace

Classes: Base, EnergyGrid2d, Eval, FftMfpt, Fftbor, Fftbor2d, Ffthairpin, Fftmultiloop, Fold, Heat, Kinwalker, Mfpt, Plot, Population, Rna2dfold, Rnabor, Spectral, Subopt, TabuPath, Xbor

Class Method Summary collapse

Class Method Details

.const_missing(name) ⇒ Object



30
31
32
33
34
35
36
37
38
# File 'lib/vienna_rna.rb', line 30

def self.const_missing(name)
  if const_defined?(name)
    const_get(name)
  elsif Base.exec_exists?(name)
    module_eval do
      const_set(name, Class.new(Base))
    end
  end
end

.lookup(package_name) ⇒ Object



3
4
5
# File 'lib/vienna_rna/package/base.rb', line 3

def self.lookup(package_name)
  const_missing("#{package_name}".camelize) || raise(ArgumentError.new("#{package_name} can't be resolved as an executable"))
end