Module: PresignedUpload::Storage
- Included in:
- Uploadable
- Defined in:
- lib/presigned_upload/storage.rb
Overview
Storage module that provides a common interface for interacting with different storage adapters.
Instance Method Summary collapse
-
#delete_file(key) ⇒ Object
Deletes the file with the specified key from the storage.
-
#presigned_url(key, method, expires_in = 3600) ⇒ String
Generates a presigned URL for the specified key, HTTP method, and expiration time.
Instance Method Details
#delete_file(key) ⇒ Object
Deletes the file with the specified key from the storage.
31 32 33 |
# File 'lib/presigned_upload/storage.rb', line 31 def delete_file(key) adapter.delete_file(key) end |
#presigned_url(key, method, expires_in = 3600) ⇒ String
Generates a presigned URL for the specified key, HTTP method, and expiration time.
23 24 25 |
# File 'lib/presigned_upload/storage.rb', line 23 def presigned_url(key, method, expires_in = 3600) adapter.presigned_url(key, method, expires_in) end |