Class: Aws::Ec2::QEc2SubnetsParser
- Defined in:
- lib/ec2/ec2.rb
Overview
:nodoc
Constant Summary
Constants inherited from AwsParser
AwsParser::DEFAULT_XML_LIBRARY
Instance Attribute Summary
Attributes inherited from AwsParser
Instance Method Summary collapse
-
#initialize(wrapper, opts = {}) ⇒ QEc2SubnetsParser
constructor
A new instance of QEc2SubnetsParser.
- #reset ⇒ Object
- #tagend(name) ⇒ Object
- #tagstart(name, attribute) ⇒ Object
Methods inherited from AwsParser
#method_missing, #parse, #tag_end, #tag_start, #tagtext, #text, xml_lib, xml_lib=
Constructor Details
#initialize(wrapper, opts = {}) ⇒ QEc2SubnetsParser
Returns a new instance of QEc2SubnetsParser.
2446 2447 2448 2449 |
# File 'lib/ec2/ec2.rb', line 2446 def initialize(wrapper, opts = {}) super(opts) @wrapper = wrapper end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Aws::AwsParser
Instance Method Details
#reset ⇒ Object
2474 2475 2476 |
# File 'lib/ec2/ec2.rb', line 2474 def reset @result = [] end |
#tagend(name) ⇒ Object
2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 |
# File 'lib/ec2/ec2.rb', line 2455 def tagend(name) case name when 'subnetId' then @subnet[:subnet_id] = @text when 'state' then @subnet[:state] = @text when 'vpcId' then @subnet[:vpc_id] = @text when 'cidrBlock' then @subnet[:cidr_block] = @text when 'availableIpAddressCount' then @subnet[:available_ip_address_count] = @text when 'availabilityZone' then @subnet[:availability_zone] = @text when @wrapper @result << @subnet end end |
#tagstart(name, attribute) ⇒ Object
2451 2452 2453 |
# File 'lib/ec2/ec2.rb', line 2451 def (name, attribute) @subnet = {} if name == @wrapper end |