Class | ParseConfig |
In: |
lib/parseconfig.rb
|
Parent: | Object |
Note: A group is a set of parameters defined for a subpart of a config file
Version | = | '0.5.2' |
config_file | [RW] | |
groups | [RW] | |
params | [RW] |
Initialize the class with the path to the ‘config_file’ The class objects are dynamically generated by the name of the ‘param’ in the config file. Therefore, if the config file is ‘param = value’ then the itializer will eval "@param = value"
This method adds an element to the config object (not the config file) By adding a Hash, you create a new group
Add parameters to a group. Note that parameters with the same name could be placed in different groups
This method will provide the value held by the object "@param" where "@param" is actually the name of the param in the config file.
DEPRECATED - will be removed in future versions
This method will set the value of ’@param’ to nil (not in the config file, only in the app).
DEPRECATED - will be removed in future versions.
This method is simple. Should you need to override a value dynamically, use override_value(param, value) where ‘param’ is the name of the paramater in the config file.
DEPRECATED - will be removed in future versions.