Method: RightAws::Ec2::QEc2DescribeLicensesParser#tagend

Defined in:
lib/ec2/right_ec2_windows_mobility.rb

#tagend(name) ⇒ Object



61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# File 'lib/ec2/right_ec2_windows_mobility.rb', line 61

def tagend(name)
  case name
  when 'licenseId'        then @item[:license_id] = @text
  when 'type'             then @item[:type]       = @text
  when 'pool'             then @item[:pool]       = @text
  when 'capacity'         then @capacity_item[:capacity]          = @text.to_i
  when 'instanceCapacity' then @capacity_item[:instance_capacity] = @text.to_i
  when 'state'            then @capacity_item[:state]             = @text
  when 'earliestAllowedDeactivationTime' then @capacity_item[:earliest_allowed_deactivation_time] = @text
  else
    case full_tag_name
    when %r{/capacitySet/item$} then @item[:capacities] << @capacity_item
    when %r{/licenseSet/item$}  then @result            << @item
    end
  end
end