1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/lib/fog/hp/models/dns/records.rb
2013-10-30 19:01:55 -04:00

26 lines
503 B
Ruby

require 'fog/core/collection'
require 'fog/hp/models/dns/record'
module Fog
module HP
class DNS
class Records < Fog::Collection
model Fog::HP::DNS : Record
def all
data = connection.list_records.body['records']
load(data)
end
def get(record_id)
record = connection.get_record_details(record_id).body['record']
new(flavor)
rescue Fog::HP::DNS::NotFound
nil
end
end
end
end
end