Class KeyPair

  • All Implemented Interfaces:
    java.lang.Comparable<KeyPair>

    public class KeyPair
    extends java.lang.Object
    implements java.lang.Comparable<KeyPair>
    A wrapper class for return values from TableAPI.tableKeysIterator(IndexKey, MultiRowOptions, oracle.kv.table.TableIteratorOptions) This classes allows the iterator to return all field value information that can be obtained directly from the index without an additional fetch. Note: this class has a natural ordering that is inconsistent with equals. Ordering is based on the indexKey only.
    Since:
    3.0
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int compareTo​(KeyPair other)
      Compares the IndexKey of this object with the IndexKey of the specified object for order.
      IndexKey getIndexKey()
      Returns the IndexKey from the pair.
      PrimaryKey getPrimaryKey()
      Returns the PrimaryKey from the pair.
      java.lang.String toJsonString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getPrimaryKey

        public PrimaryKey getPrimaryKey()
        Returns the PrimaryKey from the pair.
        Returns:
        the PrimaryKey
      • getIndexKey

        public IndexKey getIndexKey()
        Returns the IndexKey from the pair.
        Returns:
        the IndexKey
      • compareTo

        public int compareTo​(KeyPair other)
        Compares the IndexKey of this object with the IndexKey of the specified object for order. If the IndexKey values are the same a secondary comparison is done on the PrimaryKey values.
        Specified by:
        compareTo in interface java.lang.Comparable<KeyPair>
      • toJsonString

        public java.lang.String toJsonString()