Class: Module
- Inherits:
-
Object
- Object
- Module
- Defined in:
- lib/dbus/core_ext/module/remove_method.rb
Overview
copied from activesupport/core_ext from Rails, MIT license
Instance Method Summary collapse
Instance Method Details
#redefine_method(method, &block) ⇒ Object
8 9 10 11 |
# File 'lib/dbus/core_ext/module/remove_method.rb', line 8 def redefine_method(method, &block) remove_possible_method(method) define_method(method, &block) end |
#remove_possible_method(method) ⇒ Object
3 4 5 6 |
# File 'lib/dbus/core_ext/module/remove_method.rb', line 3 def remove_possible_method(method) remove_method(method) rescue NameError end |