Class: Array
- Inherits:
-
Object
- Object
- Array
- Defined in:
- lib/support.rb
Instance Method Summary collapse
-
#method_missing(method, *key) ⇒ Object
to_do: substitute with a delegation solution.
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *key) ⇒ Object
to_do: substitute with a delegation solution
14 15 16 17 18 19 |
# File 'lib/support.rb', line 14 def method_missing(method, *key) unless method == :to_hash || method == :to_str #|| method == :to_int return self.compact.map{|x| x.public_send(method, *key)} end end |