Class: Aws::Mon::QMonGetMetricStatistics

Inherits:
AwsParser show all
Defined in:
lib/ec2/right_mon_interface.rb

Constant Summary

Constants inherited from AwsParser

AwsParser::DEFAULT_XML_LIBRARY

Instance Attribute Summary

Attributes inherited from AwsParser

#result, #xml_lib, #xmlpath

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

#resetObject



165
166
167
# File 'lib/ec2/right_mon_interface.rb', line 165

def reset
    @result = []
end

#tagend(name) ⇒ Object



173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
# File 'lib/ec2/right_mon_interface.rb', line 173

def tagend(name)
    case name
        when 'Timestamp' then
            @metric[:timestamp] = @text
        when 'Samples' then
            @metric[:samples] = @text
        when 'Unit' then
            @metric[:unit] = @text
        when 'Average' then
            @metric[:average] = @text
        when 'Minimum' then
            @metric[:minimum] = @text
        when 'Maximum' then
            @metric[:maximum] = @text
        when 'Sum' then
            @metric[:sum] = @text
        when 'Value' then
            @metric[:value] = @text
        when 'member' then
            @result << @metric
    end
end

#tagstart(name, attributes) ⇒ Object



169
170
171
# File 'lib/ec2/right_mon_interface.rb', line 169

def tagstart(name, attributes)
    @metric = {} if name == 'member'
end