Method: Arrow::Config.load
- Defined in:
- lib/arrow/config.rb
.load(source, loader_obj = nil) ⇒ Object
Read and return an Arrow::Config object from the given file or configuration source using the specified loader.
178 179 180 181 182 183 184 185 186 187 188 189 190 |
# File 'lib/arrow/config.rb', line 178 def self::load( source, loader_obj=nil ) loader_obj = self.get_loader( loader_obj ) unless loader_obj.is_a?( Arrow::Config::Loader ) my_source = source.dup my_source.untaint confighash = loader_obj.load( my_source ) obj = new( confighash ) obj.loader = loader_obj obj.name = my_source return obj end |