Module: Mp3Info::HashKeys
- Included in:
- ID3v2
- Defined in:
- lib/mp3info/extension_modules.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#method_missing(meth, *args) ⇒ Object
lets you specify hash as hash.key this came from CodingInRuby on RubyGarden www.rubygarden.org/ruby?CodingInRuby.
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(meth, *args) ⇒ Object
lets you specify hash as hash.key this came from CodingInRuby on RubyGarden www.rubygarden.org/ruby?CodingInRuby
6 7 8 9 10 11 12 13 |
# File 'lib/mp3info/extension_modules.rb', line 6 def method_missing(meth,*args) m = meth.id2name if /=$/ =~ m self[m.chop] = (args.length<2 ? args[0] : args) else self[m] end end |