Class: Fog::DNS::StormOnDemand::Zones

Inherits:
Collection
  • Object
show all
Defined in:
lib/fog/dns/storm_on_demand/models/zones.rb

Instance Method Summary collapse

Instance Method Details

#all(options = {}) ⇒ Object



17
18
19
20
# File 'lib/fog/dns/storm_on_demand/models/zones.rb', line 17

def all(options = {})
  zones = service.list_zones(options).body["items"]
  load(zones)
end

#create(options) ⇒ Object



7
8
9
10
# File 'lib/fog/dns/storm_on_demand/models/zones.rb', line 7

def create(options)
  zone = service.create_zone(options).body
  new(zone)
end

#get(zone_id) ⇒ Object



12
13
14
15
# File 'lib/fog/dns/storm_on_demand/models/zones.rb', line 12

def get(zone_id)
  zone = service.get_zone(:id => zone_id).body
  new(zone)
end