Module: Rackr::Callback
- Defined in:
- lib/rackr/callback.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.assign(obj, hash) ⇒ Object
15 16 17 18 19 20 21 |
# File 'lib/rackr/callback.rb', line 15 def self.assign(obj, hash) hash.each do |k, v| obj.define_singleton_method(k) { v } end obj end |
.included(base) ⇒ Object
5 6 7 8 9 |
# File 'lib/rackr/callback.rb', line 5 def self.included(base) base.class_eval do include Rackr::Action end end |
Instance Method Details
#assign(obj, hash) ⇒ Object
11 12 13 |
# File 'lib/rackr/callback.rb', line 11 def assign(obj, hash) Rackr::Callback.assign(obj, hash) end |