Class: XmlDumper
Instance Method Summary
collapse
Methods inherited from Dumper
#initialize
Constructor Details
This class inherits a constructor from Dumper
Instance Method Details
#dump(object) ⇒ Object
53
54
55
56
57
58
59
60
|
# File 'lib/xcode-yamlizer/dumpers.rb', line 53
def dump(object)
result = CobraVsMongoose.hash_to_xml(object)
if result
File.open(@filename, 'w') do |f|
f.write result
end
end
end
|
#load ⇒ Object
61
62
63
|
# File 'lib/xcode-yamlizer/dumpers.rb', line 61
def load()
return CobraVsMongoose.xml_to_hash(IO.read(@filename))
end
|