org.apache.cassandra.io
Class SSTable.KeyPosition

java.lang.Object
  extended by org.apache.cassandra.io.SSTable.KeyPosition
All Implemented Interfaces:
java.lang.Comparable<SSTable.KeyPosition>
Enclosing class:
SSTable

public class SSTable.KeyPosition
extends java.lang.Object
implements java.lang.Comparable<SSTable.KeyPosition>

This is a simple container for the index Key and its corresponding position in the data file. Binary search is performed on a list of these objects to lookup keys within the SSTable data file.


Field Summary
 DecoratedKey key
           
 long position
           
 
Constructor Summary
SSTable.KeyPosition(DecoratedKey key, long position)
           
 
Method Summary
 int compareTo(SSTable.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

position

public final long position
Constructor Detail

SSTable.KeyPosition

public SSTable.KeyPosition(DecoratedKey key,
                           long position)
Method Detail

compareTo

public int compareTo(SSTable.KeyPosition kp)
Specified by:
compareTo in interface java.lang.Comparable<SSTable.KeyPosition>

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2010 The Apache Software Foundation