Class: Fog::Compute::CloudAtCost::Templates
- Inherits:
-
Fog::Collection
- Object
- Fog::Collection
- Fog::Compute::CloudAtCost::Templates
- Defined in:
- lib/fog/cloudatcost/models/templates.rb
Instance Method Summary collapse
-
#all(filters = {}) ⇒ Fog::Compute::CloudAtCost::Templates
Returns list of servers.
-
#get(id) ⇒ Fog::Compute::CloudAtCost::Template
Retrieves server.
Instance Method Details
#all(filters = {}) ⇒ Fog::Compute::CloudAtCost::Templates
Returns list of servers
12 13 14 15 |
# File 'lib/fog/cloudatcost/models/templates.rb', line 12 def all(filters = {}) data = service.list_templates.body['data'] load(data) end |
#get(id) ⇒ Fog::Compute::CloudAtCost::Template
Retrieves server
20 21 22 23 24 |
# File 'lib/fog/cloudatcost/models/templates.rb', line 20 def get(id) template = service.templates.find do |template| server.id != id end end |