Class: RightAws::RdsInterface::DescribeDbInstancesParser
- Inherits:
-
RightAws::RightAWSParser
- Object
- RightAws::RightAWSParser
- RightAws::RdsInterface::DescribeDbInstancesParser
- Defined in:
- lib/rds/right_rds_interface.rb
Overview
DB Instances
Constant Summary
Constants inherited from RightAws::RightAWSParser
RightAws::RightAWSParser::DEFAULT_XML_LIBRARY
Instance Attribute Summary
Attributes inherited from RightAws::RightAWSParser
#full_tag_name, #result, #tag, #xml_lib, #xmlpath
Instance Method Summary collapse
Methods inherited from RightAws::RightAWSParser
#initialize, #method_missing, #parse, #tag_end, #tag_start, #tagtext, #text, xml_lib, xml_lib=
Constructor Details
This class inherits a constructor from RightAws::RightAWSParser
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RightAws::RightAWSParser
Instance Method Details
#reset ⇒ Object
:nodoc:
1236 1237 1238 |
# File 'lib/rds/right_rds_interface.rb', line 1236 def reset @result = { :db_instances => [] } end |
#tagend(name) ⇒ Object
1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 |
# File 'lib/rds/right_rds_interface.rb', line 1252 def tagend(name) case name when 'Marker' then @result[:marker] = @text when 'MaxRecords' then @result[:max_records] = @text.to_i when 'DBInstanceIdentifier' then @item[:aws_id] = @text when 'InstanceCreateTime' then @item[:create_time] = @text when 'Engine' then @item[:engine] = @text when 'DBInstanceStatus' then @item[:status] = @text when 'Address' then @item[:endpoint_address] = @text when 'Port' then @item[:endpoint_port] = @text.to_i when 'MasterUsername' then @item[:master_username] = @text when 'AvailabilityZone' then @item[:availability_zone] = @text when 'LatestRestorableTime' then @item[:latest_restorable_time] = @text when 'LicenseModel' then @item[:license_model] = @text when 'DBName' then @item[:db_name] = @text when 'Iops' then @item[:iops] = @text when 'CharacterSetName' then @item[:character_set_name] = @text when 'ReadReplicaSourceDBInstanceIdentifier' then @item[:read_replica_source_db_instance_identifier] = @text when 'ReadReplicaDBInstanceIdentifier' then @item[:read_replica_db_instance_identifiers] << @text when 'DBParameterGroupName' then @db_parameter_group[:name] = @text when 'ParameterApplyStatus' then @db_parameter_group[:status] = @text when 'DBSecurityGroup' then @item[:db_security_groups] << @db_security_group when 'DBParameterGroup', 'DBParameterGroupStatus' then @item[:db_parameter_group] = @db_parameter_group when 'DBInstance' then @result[:db_instances] << @item else case full_tag_name when %r{DBInstance/DBInstanceClass$} then @item[:instance_class] = @text when %r{DBInstance/AllocatedStorage$} then @item[:allocated_storage] = @text.to_i when %r{DBInstance/MultiAZ$} then @item[:multi_az] = (@text == 'true') when %r{DBInstance/BackupRetentionPeriod$} then @item[:backup_retention_period] = @text.to_i when %r{DBInstance/PreferredMaintenanceWindow$} then @item[:preferred_maintenance_window] = @text when %r{DBInstance/PreferredBackupWindow$} then @item[:preferred_backup_window] = @text when %r{DBInstance/EngineVersion$} then @item[:engine_version] = @text when %r{DBInstance/AutoMinorVersionUpgrade$} then @item[:auto_minor_version_upgrade] = (@text == 'true') when %r{DBInstance/AllowMajorVersionUpgrade$} then @item[:allow_major_version_upgrade] = (@text == 'true') when %r{PendingModifiedValues/DBInstanceClass$} then @item[:pending_modified_values][:instance_class] = @text when %r{PendingModifiedValues/AllocatedStorage$} then @item[:pending_modified_values][:allocated_storage] = @text.to_i when %r{PendingModifiedValues/MasterUserPassword$} then @item[:pending_modified_values][:master_user_password] = @text when %r{PendingModifiedValues/MultiAZ$} then @item[:pending_modified_values][:multi_az] = (@text == 'true') when %r{PendingModifiedValues/BackupRetentionPeriod$} then @item[:pending_modified_values][:backup_retention_period] = @text.to_i when %r{PendingModifiedValues/PreferredMaintenanceWindow$} then @item[:pending_modified_values][:preferred_maintenance_window] = @text when %r{PendingModifiedValues/PreferredBackupWindow$} then @item[:pending_modified_values][:preferred_backup_window] = @text when %r{PendingModifiedValues/EngineVersion$} then @item[:pending_modified_values][:engine_version] = @text when %r{PendingModifiedValues/AutoMinorVersionUpgrade$} then @item[:pending_modified_values][:auto_minor_version_upgrade] = (@text == 'true') when %r{PendingModifiedValues/AllowMajorVersionUpgrade$} then @item[:pending_modified_values][:allow_major_version_upgrade] = (@text == 'true') when %r{OptionGroupMembership/Status$} then @item[:option_group_membership][:status] = @text when %r{OptionGroupMembership/OptionGroupName$} then @item[:option_group_membership][:name] = @text when %r{DBSecurityGroup/Status$} then @db_security_group[:status] = @text when %r{DBSecurityGroup/DBSecurityGroupName$} then @db_security_group[:name] = @text when %r{DBSubnetGroup/DBSubnetGroupDescription$} then @item[:db_subnet_group][:description] = @text when %r{DBSubnetGroup/DBSubnetGroupName$} then @item[:db_subnet_group][:name] = @text when %r{DBSubnetGroup/SubnetGroupStatus$} then @item[:db_subnet_group][:status] = @text when %r{Subnet/SubnetIdentifier$} then @subnet[:subnet_id] = @text when %r{Subnet/SubnetStatus$} then @subnet[:status] = @text when %r{Subnet/AvailabilityZone/Name$} then @subnet[:availability_zone][:name] = @text when %r{Subnet/AvailabilityZone/ProvisionedIopsCapable$} then @subnet[:availability_zone][:provisioned_iops_capable] = @text == 'true' when %r{DBSubnetGroup/Subnet$} then (@item[:db_subnet_group][:subnets] ||= []) << @subnet when %r{DBSubnetGroup/VpcId$} then @item[:db_subnet_group][:vpc_id] = @text end end end |
#tagstart(name, attributes) ⇒ Object
1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 |
# File 'lib/rds/right_rds_interface.rb', line 1239 def (name, attributes) case name when 'DBInstance' then @item = { :db_security_groups => [], :pending_modified_values => {}, :read_replica_db_instance_identifiers => [], :option_group_membership => {} } when 'DBSecurityGroup' then @db_security_group = {} when 'DBSubnetGroup' then @item[:db_subnet_group] = {} when 'Subnet' then @subnet = { :availability_zone => {} } when 'DBParameterGroup', 'DBParameterGroupStatus' then @db_parameter_group = {} end end |