class Fog::Storage::Dropbox::Files

Public Instance Methods

get(key, options = {}, &block) click to toggle source
# File lib/fog/dropbox/models/storage/files.rb, line 13
def get(key, options = {}, &block)
  requires :directory

  metadata = service.client.metadata(key)

  new(metadata)
rescue DropboxError
  nil
end
head(key, options = {}) click to toggle source
# File lib/fog/dropbox/models/storage/files.rb, line 23
def head(key, options = {})
  requires :directory

  metadata = service.client.metadata(key)

  new(metadata)
rescue DropboxError
  nil
end
new(attributes = {}) click to toggle source
Calls superclass method
# File lib/fog/dropbox/models/storage/files.rb, line 33
def new(attributes = {})
  requires :directory
  attributes[:name] = attributes['path'].split('/').last
  super({ :directory => directory }.merge(attributes))
end