Class: DomGlancy::MapFile
- Inherits:
-
Object
- Object
- DomGlancy::MapFile
- Defined in:
- lib/dom_glancy/map_file.rb
Instance Method Summary collapse
Instance Method Details
#read(filename) ⇒ Object
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/dom_glancy/map_file.rb', line 3 def read(filename) results = [true, '', nil] begin results[2] = YAML::load( File.open( filename ) ) rescue Exception => e results = [false, "Error reading data from file: #{filename}", nil] end results end |