lib/aerospike/command/batch_index_command.rb
def parse_row(result_code)
      generation = @data_buffer.read_int32(6)
      expiration = @data_buffer.read_int32(10)
      batch_index = @data_buffer.read_int32(14)
      field_count = @data_buffer.read_int16(18)
      op_count = @data_buffer.read_int16(20)

      key = parse_key(field_count)
      req_key = batch.key_for_index(batch_index)

      if key.digest == req_key.digest
        if result_code == 0
          record = parse_record(req_key, op_count, generation, expiration)
          results[batch_index] = record
        end
      else
        Aerospike.logger.warn("Unexpected batch key returned: #{key}")
      end
    end
def parse_row(result_code)
      generation = @data_buffer.read_int32(6)
      expiration = @data_buffer.read_int32(10)
      batch_index = @data_buffer.read_int32(14)
      field_count = @data_buffer.read_int16(18)
      op_count = @data_buffer.read_int16(20)

      key = parse_key(field_count)
      req_key = batch.key_for_index(batch_index)

      if key.digest == req_key.digest
        if result_code == 0
          record = parse_record(req_key, op_count, generation, expiration)
          results[batch_index] = record
        end
      else
        Aerospike.logger.warn("Unexpected batch key returned: #{key}")
      end
    end
Parse all results in the batch.  Add records to shared list.
 If the record was not found, the bins will be nil.