Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

JdbmTable has several helper classes which include a few Cursor implementations. These Cursors abstract the JDBM specific browsing mechanism while also adding support for traversal over duplicate keys if they have been enabled in the Table. There are six main Cursor implementations.

Introduction to Cursors

A Cursor is a data structure that allows to access inner data eiher forward or backward. The following schema expose the different kind of operations on elements that can be applied to a cursor.

Image Added

We also have some other operations that give a status :

  • isFirst()
  • isBeforeFirst()
  • isLast()
  • isAfterLast()
  • isClosed()
  • available()

and a few more operations :

  • before( Element )
  • after( Element )
  • close() and close( Exception )
  • setClosureMonitor()

No Duplicates Cursor

The no duplicates Cursor is intended for use only with JdbmTables that have duplicate keys disabled. This Cursor browses Table Tuples containing the key and the value. If duplicates are not enabled, calls to cursor() with no arguments return this Cursor implementation.

...