Method: Extlib::Hook::ClassMethods#after_class_method

Defined in:
lib/extlib/hook.rb

#after_class_method(target_method, method_sym = nil, &block) ⇒ Object

Note:

Either method_sym or block is required.

Inject code that executes after the target class method.

-

Parameters:

  • target_method (Symbol)

    the name of the class method to inject after

  • method_sym (Symbol) (defaults to: nil)

    the name of the method to run after the target_method

  • block (Block)

    the code to run after the target_method



78
79
80
# File 'lib/extlib/hook.rb', line 78

def after_class_method(target_method, method_sym = nil, &block)
  install_hook :after, target_method, method_sym, :class, &block
end