example/yaml_students/yaml_students.rb
# Save the data updated in memory.
# To change the file name, update the file attribute
Save the data updated in memory.
To change the file name, update the file attribute
Save the data updated in memory . To change the file name update the file attribute
def save_data
    begin
      File.open(@file, 'w') do |out|
        YAML.dump(@data, out)
      end
    rescue => e
      Lorj.error(format("%s\n%s", e.message, e.backtrace.join("\n")))
      return false
    end
    true
  end
def save_data begin File . open ( @file , 'w' ) do | out | YAML . dump ( @data , out ) end rescue => e Lorj . error ( format ( "%s\n%s" , e . message , e . backtrace . join ( "\n" ) ) ) return false end true end
Save the data updated in memory.
Save the data updated in memory .