# File lib/aws/simple_db/item_collection.rb, line 457 def handle_query_options(*args) options = args.last.is_a?(Hash) ? args.pop : {} if query_options = options.keys & [:select, :where, :order, :limit] and !query_options.empty? then collection = self query_options.each do |query_option| option_args = options[query_option] option_args = [option_args] unless option_args.kind_of?(Array) options.delete(query_option) collection = collection.send(query_option, *option_args) end args << options yield(collection, *args) end end