lib/data_bank.rb
# Stores a base64 encoded representation of a class at
# the end of the file specified in initialize.  On
# subsequent calls it will replace the data with the
# new data passed in.
Stores a base64 encoded representation of a class at
the end of the file specified in initialize.  On
subsequent calls it will replace the data with the
new data passed in.
Stores a base64 encoded representation of a class at the end of the file specified in initialize . On subsequent calls it will replace the data with the new data passed in .
def deposit(data)
    File.open("#{@path}/#{@filename}", 'w+') do |file|
      file.write Base64.encode64(Marshal.dump(data))
    end
  end
def deposit ( data ) File . open ( "#{@path}/#{@filename}" , 'w+' ) do | file | file . write Base64 . encode64 ( Marshal . dump ( data ) ) end end
Stores a base64 encoded representation of a class at
the end of the file specified in initialize.
Stores a base64 encoded representation of a class at the end of the file specified in initialize .
data