Class: Fog::Rackspace::Databases::Databases

Inherits:
Collection
  • Object
show all
Defined in:
lib/fog/rackspace/models/databases/databases.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#instanceObject

Returns the value of attribute instance


10
11
12
# File 'lib/fog/rackspace/models/databases/databases.rb', line 10

def instance
  @instance
end

Instance Method Details

#allObject


12
13
14
# File 'lib/fog/rackspace/models/databases/databases.rb', line 12

def all
  load(retrieve_databases)
end

#get(database_name) ⇒ Object


16
17
18
19
# File 'lib/fog/rackspace/models/databases/databases.rb', line 16

def get(database_name)
  data = retrieve_databases.find { |database| database['name'] == database_name }
  data && new(data)
end