Sha256: b44efe1e13b7a8a04e1ef380e9d76497b1d51d8e7c7356bbb0967cec6c43bdfa
Contents?: true
Size: 1.33 KB
Versions: 2
Compression:
Stored size: 1.33 KB
Contents
#-- # Amazon Web Services EC2 Query API Ruby library # # Ruby Gem Name:: amazon-ec2 # Author:: Glenn Rempe (mailto:glenn@elasticworkbench.com) # Copyright:: Copyright (c) 2007 Glenn Rempe # License:: Distributes under the same terms as Ruby # Home:: http://amazon-ec2.rubyforge.org #++ module EC2 class Base #Amazon Developer Guide Docs: # # The ConfirmProductInstance operation returns true if the given product code is attached to the instance # with the given instance id. False is returned if the product code is not attached to the instance. # #Required Arguments: # # :product_code => String (default : "") # :instance_id => String (default : "") # #Optional Arguments: # # none # def confirm_product_instance( options ={} ) options = {:product_code => "", :instance_id => ""}.merge(options) raise ArgumentError, "No product code provided" if options[:product_code].nil? || options[:product_code].empty? raise ArgumentError, "No instance ID provided" if options[:instance_id].nil? || options[:instance_id].empty? params = { "ProductCode" => options[:product_code], "InstanceId" => options[:instance_id] } return response_generator(:action => "ConfirmProductInstance", :params => params) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
amazon-ec2-0.2.3 | lib/EC2/products.rb |
amazon-ec2-0.2.4 | lib/EC2/products.rb |