Class: Fog::Storage::Artifactory::Directories

Inherits:
Collection
  • Object
show all
Defined in:
lib/fog/artifactory/models/storage/directories.rb

Instance Method Summary collapse

Instance Method Details

#allObject



10
11
12
13
# File 'lib/fog/artifactory/models/storage/directories.rb', line 10

def all
  data = service.client.get('/api/repositories')
  load(data)
end

#get(key, _options = {}) ⇒ Object



15
16
17
18
19
20
# File 'lib/fog/artifactory/models/storage/directories.rb', line 15

def get(key, _options = {})
  data = service.client.get("/api/repositories/#{key}")
  new(key: data['key'])
rescue Artifactory::Error::HTTPError => _e
  nil
end