Class: TinyUtil::ConfigUtilItem
- Inherits:
-
Object
- Object
- TinyUtil::ConfigUtilItem
show all
- Defined in:
- lib/tiny_util/config.rb
Instance Method Summary
collapse
Constructor Details
117
118
119
|
# File 'lib/tiny_util/config.rb', line 117
def initialize(item={})
@item = item || {}
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method_name, *args, &block) ⇒ Object
125
126
127
|
# File 'lib/tiny_util/config.rb', line 125
def method_missing(method_name, *args, &block)
@item[method_name.to_sym]
end
|
Instance Method Details
#[](key) ⇒ Object
121
122
123
|
# File 'lib/tiny_util/config.rb', line 121
def [] key
@item[key]
end
|