F
Francis Hwang
Is there a way to capture whenever a class method is added either to a
base class or its children? For example, if my code is
class A
def self.some_method
...
end
end
class B < A
def self.some_method
...
end
end
I want to be notified twice. Defining A.singleton_method_added only
seems to work for the definition of A.some_method, but won't catch the
definition of B.some_method.
Francis Hwang
http://fhwang.net/
base class or its children? For example, if my code is
class A
def self.some_method
...
end
end
class B < A
def self.some_method
...
end
end
I want to be notified twice. Defining A.singleton_method_added only
seems to work for the definition of A.some_method, but won't catch the
definition of B.some_method.
Francis Hwang
http://fhwang.net/