Class: Backup::Storage::Dropbox
- Defined in:
- lib/backup/storage/dropbox.rb
Instance Attribute Summary collapse
-
#access_type ⇒ Object
Dropbox Access Type Valid values are: :app_folder (default) :dropbox (full access).
-
#api_key ⇒ Object
Dropbox API credentials.
-
#api_secret ⇒ Object
Dropbox API credentials.
-
#path ⇒ Object
Path to where the backups will be stored.
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(model, storage_id = nil, &block) ⇒ Dropbox
constructor
Creates a new instance of the storage object.
Methods inherited from Base
Methods included from Configuration::Helpers
Constructor Details
#initialize(model, storage_id = nil, &block) ⇒ Dropbox
Creates a new instance of the storage object
33 34 35 36 37 38 39 40 |
# File 'lib/backup/storage/dropbox.rb', line 33 def initialize(model, storage_id = nil, &block) super(model, storage_id) @path ||= 'backups' @access_type ||= :app_folder instance_eval(&block) if block_given? end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Backup::Configuration::Helpers
Instance Attribute Details
#access_type ⇒ Object
Dropbox Access Type Valid values are:
:app_folder (default)
:dropbox (full access)
20 21 22 |
# File 'lib/backup/storage/dropbox.rb', line 20 def access_type @access_type end |
#api_key ⇒ Object
Dropbox API credentials
13 14 15 |
# File 'lib/backup/storage/dropbox.rb', line 13 def api_key @api_key end |
#api_secret ⇒ Object
Dropbox API credentials
13 14 15 |
# File 'lib/backup/storage/dropbox.rb', line 13 def api_secret @api_secret end |
#path ⇒ Object
Path to where the backups will be stored
24 25 26 |
# File 'lib/backup/storage/dropbox.rb', line 24 def path @path end |