lib/amazon_sdb/domain.rb
def delete_attributes(key, multimap=nil)
        options = {'Action' => 'DeleteAttributes', 'DomainName' => name, 'ItemName' => key}
        
        unless multimap.nil?
          case multimap
          when String, Symbol
            options.merge! "Attribute.0.Name" => multimap.to_s
          when Array
            multimap.each_with_index do |k, i|
              options["Attribute.#{i}.Name"] = k
            end
          when Hash
            options.merge! Multimap.new(multimap).to_sdb
          when Multimap
            options.merge! multimap.to_sdb
          else
            raise ArgumentError, "Bad input paramter for attributes"
          end
        end
        
        sdb_query(options) do |h|
          if h.search('//Success').any?
            return true
          end
        end
      end
##
# Deletes the attributes associated with a particular item. If the optional <tt>multimap</tt> argument is nil, deletes the entire
# object. Otherwise, the optional multimap argument can be used to delete specific key/value pairs in the object (also accepts
# a String or Symbol for a single name, an Array for multiple keys or a Hash for key/value pairs)
Deletes the attributes associated with a particular item. If the optional multimap argument is nil, deletes the entire
object. Otherwise, the optional multimap argument can be used to delete specific key/value pairs in the object (also accepts
a String or Symbol for a single name, an Array for multiple keys or a Hash for key/value pairs)
Deletes the attributes associated with a particular item . If the optional multimap argument is nil deletes the entire object . Otherwise the optional multimap argument can be used to delete specific key / value pairs in the object ( also accepts a String or Symbol for a single name an Array for multiple keys or a Hash for key / value pairs )
def delete_attributes(key, multimap=nil)
        options = {'Action' => 'DeleteAttributes', 'DomainName' => name, 'ItemName' => key}
        unless multimap.nil?
          case multimap
          when String, Symbol
            options.merge! "Attribute.0.Name" => multimap.to_s
          when Array
            multimap.each_with_index do |k, i|
              options["Attribute.#{i}.Name"] = k
            end
          when Hash
            options.merge! Multimap.new(multimap).to_sdb
          when Multimap
            options.merge! multimap.to_sdb
          else
            raise ArgumentError, "Bad input paramter for attributes"
          end
        end
        sdb_query(options) do |h|
          if h.search('//Success').any?
            return true
          end
        end
      end
def delete_attributes ( key , multimap = nil ) options = { 'Action' => 'DeleteAttributes' , 'DomainName' => name , 'ItemName' => key } unless multimap . nil? case multimap when String , Symbol options . merge! "Attribute.0.Name" => multimap . to_s when Array multimap . each_with_index do | k , i | options [ "Attribute.#{i}.Name" ] = k end when Hash options . merge! Multimap . new ( multimap ) . to_sdb when Multimap options . merge! multimap . to_sdb else raise ArgumentError , "Bad input paramter for attributes" end end sdb_query ( options ) do | h | if h . search ( '//Success' ) . any? return true end end end
Deletes the attributes associated with a particular item.
Deletes the attributes associated with a particular item .
key
multimap