Class: YDD::YamlDB::Load
- Inherits:
-
SerializationHelper::Load
- Object
- SerializationHelper::Load
- YDD::YamlDB::Load
- Defined in:
- lib/ydd/yaml_db.rb
Class Method Summary collapse
Methods inherited from SerializationHelper::Load
clean_column_value, convert_from, load, load_records, load_table, reset_pk_sequence!, truncate_table
Class Method Details
.load_documents(io, truncate = true) ⇒ Object
53 54 55 56 57 58 59 60 |
# File 'lib/ydd/yaml_db.rb', line 53 def self.load_documents(io, truncate = true) YAML.load_documents(io) do |ydoc| ydoc.keys.each do |table_name| next if ydoc[table_name].nil? load_table(table_name, ydoc[table_name], truncate) end end end |