Method: VirtualBox::ExtraData#save
- Defined in:
- lib/virtualbox/extra_data.rb
#save ⇒ Boolean
Saves extra data. This method does the same thing for both new and existing extra data, since virtualbox will overwrite old data or create it if it doesn’t exist.
103 104 105 106 107 108 109 110 111 112 113 114 |
# File 'lib/virtualbox/extra_data.rb', line 103 def save changes.each do |key, value| interface.set_extra_data(key.to_s, value[1].to_s) clear_dirty!(key) if value[1].nil? # Remove the key from the hash altogether hash_delete(key.to_s) end end end |