Package acdp

Interface Table.TableIterator

All Superinterfaces:
Iterator<Row>
Enclosing interface:
Table

public static interface Table.TableIterator extends Iterator<Row>
Defines an iterator over the rows of a given table.
Author:
Beat Hörmann
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns true if and only if the iteration has more rows.
    Returns the next row of the table.
    void
    The remove method is not supported by this iterator.

    Methods inherited from interface java.util.Iterator

    forEachRemaining
  • Method Details

    • hasNext

      Returns true if and only if the iteration has more rows. (In other words, returns true if the next() method would return a row rather than throwing a NoSuchElementException.)
      Specified by:
      hasNext in interface Iterator<Row>
      Returns:
      The boolean value true if the iteration has more rows, false if the iteration has no more rows.
      Throws:
      CryptoException - If decryption fails. This exception never happens if the database does not apply encryption or if the database is an RO database.
      ShutdownException - If the database is closed. This exception never happens if this iterator is executed within a read zone or unit or if the database is an RO database.
      IOFailureException - If an I/O error occurs. This exception never happens if the database is an RO database and the operating mode is "memory unpacked" (-3).
    • next

      Returns the next row of the table.

      In case of table data corruption this method may throw an exception of a type not listed below. If the database is a writable database then temporary table data corruption may be due to concurrent writes. Execute this method inside a read zone or a unit to ensure that no concurrent writes are taken place in the database while this method is being executed.

      Specified by:
      next in interface Iterator<Row>
      Returns:
      The next row in the table.
      Throws:
      NoSuchElementException - If the iteration has no more elements.
      CryptoException - If decryption fails. This exception never happens if the database does not apply encryption or if the database is an RO database.
      ShutdownException - If the database is closed. This exception never happens if this iterator is executed within a read zone or a unit or if the database is an RO database and the operating mode is "memory packed" (-2) or "memory unpacked" (-3).
      IOFailureException - If an I/O error occurs. This exception never happens if the database is an RO database and the operating mode is "memory unpacked" (-3).
    • remove

      void remove() throws UnsupportedOperationException
      The remove method is not supported by this iterator.
      Specified by:
      remove in interface Iterator<Row>
      Throws:
      UnsupportedOperationException - Always.