Class: CarrierWave::Storage::TencentCos
- Inherits:
-
Abstract
- Object
- Abstract
- CarrierWave::Storage::TencentCos
- Defined in:
- lib/carrierwave/storage/tencent_cos.rb
Defined Under Namespace
Classes: File
Instance Method Summary collapse
-
#retrieve!(identifier) ⇒ Object
Load and return a file instance from your engine.
-
#store!(file) ⇒ Object
Create and save a file instance to your engine.
Instance Method Details
#retrieve!(identifier) ⇒ Object
Load and return a file instance from your engine.
15 16 17 |
# File 'lib/carrierwave/storage/tencent_cos.rb', line 15 def retrieve!(identifier) CarrierWave::Storage::TencentCos::File.new(uploader.store_path(identifier)) end |
#store!(file) ⇒ Object
Create and save a file instance to your engine.
8 9 10 11 12 |
# File 'lib/carrierwave/storage/tencent_cos.rb', line 8 def store!(file) f = CarrierWave::Storage::TencentCos::File.new(uploader.store_path) f.store(file) f end |