class Dropbox::API::File
Public Instance Methods
copy_ref(options = {})
click to toggle source
# File lib/dropbox-api/objects/file.rb, line 22 def copy_ref(options = {}) response = client.raw.copy_ref({ :path => self.path }.merge(options)) Dropbox::API::Object.init(response, client) end
direct_url(options = {})
click to toggle source
# File lib/dropbox-api/objects/file.rb, line 31 def direct_url(options = {}) response = client.raw.media({ :path => self.path }.merge(options)) Dropbox::API::Object.init(response, client) end
download()
click to toggle source
# File lib/dropbox-api/objects/file.rb, line 27 def download client.download(self.path) end
restore(rev, options = {})
click to toggle source
# File lib/dropbox-api/objects/file.rb, line 13 def restore(rev, options = {}) response = client.raw.restore({ :rev => rev, :path => self.path }.merge(options)) self.update response end
revisions(options = {})
click to toggle source
# File lib/dropbox-api/objects/file.rb, line 8 def revisions(options = {}) response = client.raw.revisions({ :path => self.path }.merge(options)) Dropbox::API::Object.convert(response, client) end
thumbnail(options = {})
click to toggle source
# File lib/dropbox-api/objects/file.rb, line 18 def thumbnail(options = {}) client.raw.thumbnails({ :path => self.path }.merge(options)) end