Class DBCursor

java.lang.Object
overit.geocall.sql.DBCursor
All Implemented Interfaces:
AutoCloseable

public class DBCursor extends Object implements AutoCloseable
A cursor over a ResultSet
  • Field Details

  • Constructor Details

    • DBCursor

      public DBCursor(DBStatement dbs) throws SQLException
      contruct a cursor over the statement parameter
      Parameters:
      dbs - the statement providing the cursor
      Throws:
      SQLException - in case of an sql error
  • Method Details

    • getCursor

      public ResultSet getCursor()
      retrieves the cursor, i.e. a ResultSet
      Returns:
      the cursor, i.e. a ResultSet
    • getRowMap

      public HashGetter getRowMap() throws SQLException
      reads all ther record in the current cursor position, transforming it into a map followinf the dbstatement definitions naming
      Returns:
      a Map containing a record in the current cursor position
      Throws:
      SQLException - in the case of an sql error
    • close

      public void close() throws SQLException
      closes the underlying ResultSet
      Specified by:
      close in interface AutoCloseable
      Throws:
      SQLException - in the case of an sql error