mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Matthew Swift
31.00.2015 8513213e8f8f1cd4d87a10b3218654c6988f5188
opendj-server-legacy/src/main/java/org/opends/server/backends/persistit/PersistItStorage.java
@@ -177,6 +177,29 @@
    }
    @Override
    public boolean positionToIndex(int index)
    {
      // There doesn't seem to be a way to optimize this using Persistit.
      try
      {
        clearCurrentKeyAndValue();
        ex.getKey().to(Key.BEFORE);
        for (int i = 0; i < index; i++)
        {
          if (!ex.next())
          {
            return false;
          }
        }
        return true;
      }
      catch (final PersistitException e)
      {
        throw new StorageRuntimeException(e);
      }
    }
    @Override
    public boolean positionToLastKey()
    {
      try