Interface DBIterator

All Superinterfaces:
AutoCloseable, Closeable, Iterator<Map.Entry<byte[],byte[]>>
All Known Implementing Classes:
SeekingIteratorAdapter

public interface DBIterator extends Iterator<Map.Entry<byte[],byte[]>>, Closeable
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    Map.Entry<byte[],byte[]>
    Returns the next element in the iteration, without advancing the iteration.
    Map.Entry<byte[],byte[]>
     
    Map.Entry<byte[],byte[]>
     
    void
    seek(byte[] key)
    Repositions the iterator so the key of the next BlockElement returned greater than or equal to the specified targetKey.
    void
    Repositions the iterator so is is at the beginning of the Database.
    void
    Repositions the iterator so it is at the end of of the Database.

    Methods inherited from interface java.io.Closeable

    close

    Methods inherited from interface java.util.Iterator

    forEachRemaining, hasNext, next, remove
  • Method Details

    • seek

      void seek(byte[] key)
      Repositions the iterator so the key of the next BlockElement returned greater than or equal to the specified targetKey.
    • seekToFirst

      void seekToFirst()
      Repositions the iterator so is is at the beginning of the Database.
    • peekNext

      Map.Entry<byte[],byte[]> peekNext()
      Returns the next element in the iteration, without advancing the iteration.
    • hasPrev

      boolean hasPrev()
      Returns:
      true if there is a previous entry in the iteration.
    • prev

      Map.Entry<byte[],byte[]> prev()
      Returns:
      the previous element in the iteration and rewinds the iteration.
    • peekPrev

      Map.Entry<byte[],byte[]> peekPrev()
      Returns:
      the previous element in the iteration, without rewinding the iteration.
    • seekToLast

      void seekToLast()
      Repositions the iterator so it is at the end of of the Database.