Class: Aws::AcfInterface::AcfDistributionListParser

Inherits:
Aws::AwsParser show all
Defined in:
lib/acf/right_acf_interface.rb

Overview


PARSERS:

Constant Summary

Constants inherited from Aws::AwsParser

Aws::AwsParser::DEFAULT_XML_LIBRARY

Instance Attribute Summary

Attributes inherited from Aws::AwsParser

#result, #xml_lib, #xmlpath

Instance Method Summary collapse

Methods inherited from Aws::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

#resetObject

:nodoc:



328
329
330
# File 'lib/acf/right_acf_interface.rb', line 328

def reset
  @result = []
end

#tagend(name) ⇒ Object



334
335
336
337
338
339
340
341
342
343
344
345
# File 'lib/acf/right_acf_interface.rb', line 334

def tagend(name)
  case name
    when 'Id'                  then @distribution[:aws_id]             = @text
    when 'Status'              then @distribution[:status]             = @text
    when 'LastModifiedTime'    then @distribution[:last_modified_time] = Time.parse(@text)
    when 'DomainName'          then @distribution[:domain_name]        = @text
    when 'Origin'              then @distribution[:origin]             = @text
    when 'Comment'             then @distribution[:comment]            = AcfInterface::unescape(@text)
    when 'CNAME'               then @distribution[:cnames]            << @text
    when 'DistributionSummary' then @result << @distribution
  end
end

#tagstart(name, attributes) ⇒ Object



331
332
333
# File 'lib/acf/right_acf_interface.rb', line 331

def tagstart(name, attributes)
  @distribution = { :cnames => [] } if name == 'DistributionSummary'
end