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/xenserver/parser.rb
2012-04-02 13:25:03 +02:00

29 lines
No EOL
499 B
Ruby

module Fog
module Parsers
module XenServer
class Base
attr_reader :response
def initialize
reset
end
def reset
@response = {}
end
def parse( data )
if data.is_a? Hash
@response = data.symbolize_keys!
elsif data.is_a? Array
@response = data.first
end
@response
end
end
end
end
end