Method: Extlib::Hook::ClassMethods#before
- Defined in:
- lib/extlib/hook.rb
#before(target_method, method_sym = nil, &block) ⇒ Object
Note:
Either method_sym or block is required.
Inject code that executes before the target instance method.
-
94 95 96 |
# File 'lib/extlib/hook.rb', line 94 def before(target_method, method_sym = nil, &block) install_hook :before, target_method, method_sym, :instance, &block end |