Class: Aws::Ec2::QEc2DescribeImageAttributeParser
- Defined in:
- lib/ec2/ec2.rb
Overview
PARSERS: Image Attribute
Constant Summary
Constants inherited from AwsParser
AwsParser::DEFAULT_XML_LIBRARY
Instance Attribute Summary
Attributes inherited from AwsParser
Instance Method Summary collapse
Methods inherited from AwsParser
#initialize, #method_missing, #parse, #tag_end, #tag_start, #tagtext, #text, xml_lib, xml_lib=
Constructor Details
This class inherits a constructor from Aws::AwsParser
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Aws::AwsParser
Instance Method Details
#reset ⇒ Object
1561 1562 1563 |
# File 'lib/ec2/ec2.rb', line 1561 def reset @result = {} end |
#tagend(name) ⇒ Object
1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 |
# File 'lib/ec2/ec2.rb', line 1539 def tagend(name) # right now only 'launchPermission' is supported by Amazon. # But nobody know what will they xml later as attribute. That is why we # check for 'group' and 'userId' inside of 'launchPermission/item' case name when 'imageId' then @result[:aws_id] = @text when 'group' then @result[:groups] << @text if @xmlpath == 'DescribeImageAttributeResponse/launchPermission/item' when 'userId' then @result[:users] << @text if @xmlpath == 'DescribeImageAttributeResponse/launchPermission/item' when 'productCode' then @result[:aws_product_codes] << @text when 'kernel' then @result[:aws_kernel] = @text when 'ramdisk' then @result[:aws_ramdisk] = @text when 'blockDeviceMapping' then @result[:block_device_mapping] = @text end end |
#tagstart(name, attributes) ⇒ Object
:nodoc:
1529 1530 1531 1532 1533 1534 1535 1536 1537 |
# File 'lib/ec2/ec2.rb', line 1529 def (name, attributes) case name when 'launchPermission' @result[:groups] = [] @result[:users] = [] when 'productCodes' @result[:aws_product_codes] = [] end end |