@Override
  public boolean traverseAllRecords(final @NotNull RecordsProcessor p) throws IOException {
    getReadLock().lock();
    try {
      lockStorageRead();
      try {
        return myBTree.processMappings(new IntToIntBtree.KeyValueProcessor() {
          @Override
          public boolean process(int key, int value) throws IOException {
            p.setCurrentKey(key);

            if (value > 0 || myInlineKeysNoMapping) {
              return p.process(value);
            }
            //collision resolution:
            // value = -offset of a 0-terminated array of ids in a collisionResolutionStorage:
            int nextEntryOffset = -value;
            while (nextEntryOffset != 0) {
              int id = myCollisionResolutionStorage.getInt(nextEntryOffset);
              if (!p.process(id)) return false;
              nextEntryOffset = myCollisionResolutionStorage.getInt(nextEntryOffset + COLLISION_OFFSET);
            }
            return true;
          }
        });
      }
      finally {
        unlockStorageRead();
      }
    }
    finally {
      getReadLock().unlock();
    }
  }
@Override
  public boolean traverseAllRecords(final @NotNull RecordsProcessor p)