Module: Orthoses::Mixin::Hook

Defined in:
lib/orthoses/mixin.rb

Instance Method Summary collapse

Instance Method Details

#extend(*modules) ⇒ Object



14
15
16
17
18
19
# File 'lib/orthoses/mixin.rb', line 14

def extend(*modules)
  modules.each do |m|
    (CALL_GRAPH[self]||=[]) << [:extend, m]
  end
  super
end

#include(*modules) ⇒ Object



8
9
10
11
12
13
# File 'lib/orthoses/mixin.rb', line 8

def include(*modules)
  modules.each do |m|
    (CALL_GRAPH[self]||=[]) << [:include, m]
  end
  super
end

#prepend(*modules) ⇒ Object



20
21
22
23
24
25
# File 'lib/orthoses/mixin.rb', line 20

def prepend(*modules)
  modules.each do |m|
    (CALL_GRAPH[self]||=[]) << [:prepend, m]
  end
  super
end