Class: Fog::Parsers::CDN::AWS::GetInvalidationList

Inherits:
Base
  • Object
show all
Defined in:
lib/fog/aws/parsers/cdn/get_invalidation_list.rb

Instance Attribute Summary

Attributes inherited from Base

#response

Instance Method Summary (collapse)

Methods inherited from Base

#attr_value, #characters, #end_element_namespace, #initialize, #start_element_namespace, #value

Constructor Details

This class inherits a constructor from Fog::Parsers::Base

Instance Method Details

- (Object) end_element(name)



17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# File 'lib/fog/aws/parsers/cdn/get_invalidation_list.rb', line 17

def end_element(name)
  case name
  when 'InvalidationSummary'
    @response['InvalidationSummary'] << @invalidation_summary
    @invalidation_summary = {}
  when 'Id', 'Status'
    @invalidation_summary[name] = @value
  when 'IsTruncated'
    if @value == 'true'
      @response[name] = true
    else
      @response[name] = false
    end
  when 'Marker', 'NextMarker'
    @response[name] = @value
  when 'MaxItems'
    @response[name] = @value.to_i
  end
end

- (Object) reset



8
9
10
11
# File 'lib/fog/aws/parsers/cdn/get_invalidation_list.rb', line 8

def reset
  @invalidation_summary = { }
  @response = { 'InvalidationSummary' => [] }
end

- (Object) start_element(name, attrs = [])



13
14
15
# File 'lib/fog/aws/parsers/cdn/get_invalidation_list.rb', line 13

def start_element(name, attrs = [])
  super
end