## org.apache.cassandra.io.sstable
Class IndexSummary.KeyPosition

    java.lang.Object
      org.apache.cassandra.io.sstable.IndexSummary.KeyPosition

All Implemented Interfaces:
  java.lang.Comparable<IndexSummary.KeyPosition>

Enclosing class:
  IndexSummary

    public static final class IndexSummary.KeyPosition

extends java.lang.Object
implements java.lang.Comparable<IndexSummary.KeyPosition>

This is a simple container for the index Key and its corresponding position in the index file. Binary search is performed on a list of these objects to find where to start looking for the index entry containing the data position (which will be turned into a PositionSize object)

Field Summary
`long` `indexPosition`
`DecoratedKey<?>` `key`

Constructor Summary
`IndexSummary.KeyPosition(DecoratedKey<?> key, long indexPosition)`

Method Summary
`int` `compareTo(IndexSummary.KeyPosition kp)`
`java.lang.String` `toString()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### key

    public final DecoratedKey<?> key

### indexPosition

    public final long indexPosition

Constructor Detail

### IndexSummary.KeyPosition

    public IndexSummary.KeyPosition(DecoratedKey<?> key,
                                    long indexPosition)

Method Detail

### compareTo

    public int compareTo(IndexSummary.KeyPosition kp)

  Specified by:
    `compareTo` in interface `java.lang.Comparable<IndexSummary.KeyPosition>`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

Copyright © 2012 The Apache Software Foundation