def parse_xml_attributes!(xml)
@description = ((xml/'description').first.text rescue '')
@status = ((xml/'status').first.text rescue 'unknown')
@memory = (xml/'memory').first.text
@profile = (xml/'type').first.text
@cluster = Link::new(@client, (xml/'cluster').first[:id], (xml/'cluster').first[:href])
@display = {
:type => (xml/'display/type').first.text,
:monitors => (xml/'display/monitors').first.text
}
@cores = ((xml/'cpu/topology').first[:cores].to_i * (xml/'cpu/topology').first[:sockets].to_i rescue nil)
@storage = ((xml/'disks/disk/size').first.text rescue nil)
@creation_time = (xml/'creation_time').text
@os = {
:type => (xml/'os').first[:type],
:boot => (xml/'os/boot').collect {|boot| boot[:dev] }
}
end