Class: Quince::Callback
- Inherits:
-
Object
- Object
- Quince::Callback
- Includes:
- Interface
- Defined in:
- lib/quince/callback.rb
Defined Under Namespace
Modules: ComponentHelpers, Interface
Instance Attribute Summary
Attributes included from Interface
Instance Method Summary collapse
-
#initialize(receiver, method_name, **opts) ⇒ Callback
constructor
A new instance of Callback.
Constructor Details
#initialize(receiver, method_name, **opts) ⇒ Callback
Returns a new instance of Callback.
39 40 41 42 43 44 45 46 47 48 |
# File 'lib/quince/callback.rb', line 39 def initialize( receiver, method_name, **opts ) @receiver, @method_name = receiver, method_name ComponentHelpers::DEFAULT_CALLBACK_OPTIONS.each_key do |opt| instance_variable_set :"@#{opt}", opts.fetch(opt) end end |