# File lib/aws/dynamo_db/item_collection.rb, line 796
      def _yield_items mode, response, &block

        case mode

        # yield the count of items matching
        when :count
          yield(response.data["Count"])

        # yeild item data objects
        when :item_data

          table.assert_schema!

          #construct_items =
          #  (true if request_includes_key?(response.request_options))

          construct_items = request_includes_key?(response.request_options)

          response.data["Items"].each do |i|
            attributes = values_from_response_hash(i)

            item = nil
            item = Item.new_from(:put_item, i, table) if construct_items

            item_data = ItemData.new(:item => item, :attributes => attributes)

            yield(item_data)

          end

        # yield item objects
        when :item
          response.data["Items"].each do |i|
            item = Item.new_from(:put_item, i, table)
            yield(item)
          end

        end

      end