Class: SoarSc::Web::Views::ERBLoader::ERBNamespace

Inherits:
Object
  • Object
show all
Defined in:
lib/soar_sc_views/erb_loader.rb

Instance Method Summary collapse

Constructor Details

#initialize(hash) ⇒ ERBNamespace

Returns a new instance of ERBNamespace.



9
10
11
12
13
# File 'lib/soar_sc_views/erb_loader.rb', line 9

def initialize(hash)
  hash.each do |k, v|
    singleton_class.send(:define_method, k) { v }
  end
end

Instance Method Details

#get_bindingObject



15
16
17
# File 'lib/soar_sc_views/erb_loader.rb', line 15

def get_binding
  binding
end