Class: Cryptoform::StorageBackends::File
- Inherits:
-
Backend
- Object
- Backend
- Cryptoform::StorageBackends::File
- Defined in:
- lib/cryptoform/storage_backends/file.rb
Instance Method Summary collapse
Instance Method Details
#read ⇒ Object
4 5 6 7 8 |
# File 'lib/cryptoform/storage_backends/file.rb', line 4 def read ::File.read(filename) rescue Errno::ENOENT raise Cryptoform::StateMissingError, "state '#{@state_name}' is configured but missing" end |
#write(data) ⇒ Object
10 11 12 |
# File 'lib/cryptoform/storage_backends/file.rb', line 10 def write(data) ::File.write(filename, data) end |