Class: Storable::Anonymous
- Inherits:
-
Object
- Object
- Storable::Anonymous
- Defined in:
- lib/storable.rb
Instance Method Summary collapse
- #[](key) ⇒ Object
-
#initialize(from) ⇒ Anonymous
constructor
A new instance of Anonymous.
- #method_missing(meth, *args) ⇒ Object
Constructor Details
#initialize(from) ⇒ Anonymous
Returns a new instance of Anonymous.
493 494 495 |
# File 'lib/storable.rb', line 493 def initialize from @hash = from end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(meth, *args) ⇒ Object
499 500 501 |
# File 'lib/storable.rb', line 499 def method_missing(meth,*args) @hash[meth.to_sym] end |
Instance Method Details
#[](key) ⇒ Object
496 497 498 |
# File 'lib/storable.rb', line 496 def [](key) @hash[meth.to_sym] end |