Class CollectionBackedScanner

All Implemented Interfaces:
Closeable, AutoCloseable, KeyValueScanner, Shipper

Utility scanner that wraps a sortable collection and serves as a KeyValueScanner.
  • Field Details

  • Constructor Details

  • Method Details

    • init

      private void init()
    • peek

      public Cell peek()
      Description copied from interface: KeyValueScanner
      Look at the next Cell in this scanner, but do not iterate scanner. NOTICE: The returned cell has not been passed into ScanQueryMatcher. So it may not be what the user need.
      Returns:
      the next Cell
    • next

      public Cell next()
      Description copied from interface: KeyValueScanner
      Return the next Cell in this scanner, iterating the scanner
      Returns:
      the next Cell
    • seek

      public boolean seek(Cell seekCell)
      Description copied from interface: KeyValueScanner
      Seek the scanner at or after the specified KeyValue.
      Parameters:
      seekCell - seek value
      Returns:
      true if scanner has values left, false if end of scanner
    • reseek

      public boolean reseek(Cell seekCell)
      Description copied from interface: KeyValueScanner
      Reseek the scanner at or after the specified KeyValue. This method is guaranteed to seek at or after the required key only if the key comes after the current position of the scanner. Should not be used to seek to a key which may come before the current position.
      Parameters:
      seekCell - seek value (should be non-null)
      Returns:
      true if scanner has values left, false if end of scanner
    • close

      public void close()
      Description copied from interface: KeyValueScanner
      Close the KeyValue scanner.