Class: Object
- Inherits:
- BasicObject
- Defined in:
- lib/method_describer/method_desc.rb
Overview
TODO mixin from a separate module
Instance Method Summary collapse
-
#desc_method(name, options = {}) ⇒ Object
currently rather verbose, but will attempt to describe all it knows about a method.
Instance Method Details
#desc_method(name, options = {}) ⇒ Object
currently rather verbose, but will attempt to describe all it knows about a method
142 143 144 145 146 147 148 149 |
# File 'lib/method_describer/method_desc.rb', line 142 def desc_method name, = {} if self.is_a? Class # i.e. String.strip instance_method(name).desc() rescue method(name).desc() # rescue allows for Class.instance_method_name else method(name).desc() end end |