| Module | Mixlib::Config |
| In: |
lib/mixlib/config.rb
|
Get the value of a configuration option
| config_option<Symbol>: | The configuration option to return |
| value: | The value of the configuration option |
| <ArgumentError>: | If the configuration option does not exist |
Set the value of a configuration option
| config_option<Symbol>: | The configuration option to set (within the []) |
| value: | The value for the configuration option |
| value: | The new value of the configuration option |
metaprogramming to ensure that the slot for method_symbol gets set to value after any other logic is run
| method_symbol<Symbol>: | Name of the method (variable setter) |
| blk<Block>: | logic block to run in setting slot method_symbol to value |
| value<Object>: | Value to be set in config hash |
Pass Mixlib::Config.configure() a block, and it will yield self.configuration.
| <block>: | A block that is sent self.configuration as its argument |
Loads a given ruby file, and runs instance_eval against it in the context of the current object.
Raises an IOError if the file cannot be found, or is not readable.
| <string>: | A filename to read from |
Check if Mixlib::Config has a configuration option.
| key<Symbol>: | The configuration option to check for |
| <True>: | If the configuration option exists |
| <False>: | If the configuration option does not exist |
Merge an incoming hash with our config options
| hash<Hash>: | The incoming hash |
result of Hash#merge!
Allows for simple lookups and setting of configuration options via method calls on Mixlib::Config. If there any arguments to the method, they are used to set the value of the configuration option. Otherwise, it‘s a simple get operation.
| method_symbol<Symbol>: | The method called. Must match a configuration option. |
| *args: | Any arguments passed to the method |
| value: | The value of the configuration option. |
| <ArgumentError>: | If the method_symbol does not match a configuration option. |