void forEachRoot(final @NotNull BiConsumer<Integer, Integer> rootConsumer) throws IOException {
    rootsAccessLock.lock();
    try {
      try (final DataInputStream input = attributeAccessor.readAttribute(SUPER_ROOT_ID, CHILDREN_ATTR)) {
        if (input != null) {
          final int count = DataInputOutputUtil.readINT(input);
          if (count < 0) {
            throw new IOException("SUPER_ROOT.CHILDREN attribute is corrupted: roots count(=" + count + ") must be >=0");
          }
          int prevId = 0;
          int prevNameId = 0;

          for (int i = 0; i < count; i++) {
            final int nameId = DataInputOutputUtil.readINT(input) + prevNameId;
            final int rootId = DataInputOutputUtil.readINT(input) + prevId;
            prevNameId = nameId;
            prevId = rootId;

            rootConsumer.accept(rootId, nameId);
          }
        }
      }
    }
    finally {
      rootsAccessLock.unlock();
    }
  }
void forEachRoot(final @NotNull BiConsumer<Integer, Integer> rootConsumer)