org.apache.cassandra.db.index.keys
Class KeysIndex

java.lang.Object
  extended by org.apache.cassandra.db.index.SecondaryIndex
      extended by org.apache.cassandra.db.index.PerColumnSecondaryIndex
          extended by org.apache.cassandra.db.index.AbstractSimplePerColumnSecondaryIndex
              extended by org.apache.cassandra.db.index.keys.KeysIndex

public class KeysIndex
extends AbstractSimplePerColumnSecondaryIndex

Implements a secondary index for a column family using a second column family in which the row keys are indexed values, and column names are base row keys.


Field Summary
 
Fields inherited from class org.apache.cassandra.db.index.SecondaryIndex
baseCfs, columnDefs, CUSTOM_INDEX_OPTION_NAME, logger
 
Constructor Summary
KeysIndex()
           
 
Method Summary
 SecondaryIndexSearcher createSecondaryIndexSearcher(java.util.Set<java.nio.ByteBuffer> columns)
          Called at query time Creates a implementation specific searcher instance for this index type
protected  AbstractType getExpressionComparator()
           
 void init(ColumnDefinition columnDef)
           
protected  java.nio.ByteBuffer makeIndexColumnName(java.nio.ByteBuffer rowKey, IColumn column)
           
 void validateOptions()
          Validates the index_options passed in the ColumnDef
 
Methods inherited from class org.apache.cassandra.db.index.AbstractSimplePerColumnSecondaryIndex
delete, expressionString, forceBlockingFlush, getIndexCfs, getIndexName, getLiveSize, init, insert, invalidate, reload, removeIndex, truncate, update
 
Methods inherited from class org.apache.cassandra.db.index.PerColumnSecondaryIndex
getNameForSystemTable, validate
 
Methods inherited from class org.apache.cassandra.db.index.SecondaryIndex
buildIndexAsync, buildIndexBlocking, createInstance, getBaseCfs, getColumnDefs, getIndexComparator, getIndexKeyFor, indexes, isIndexBuilt, setIndexBuilt, setIndexRemoved
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeysIndex

public KeysIndex()
Method Detail

init

public void init(ColumnDefinition columnDef)
Specified by:
init in class AbstractSimplePerColumnSecondaryIndex

makeIndexColumnName

protected java.nio.ByteBuffer makeIndexColumnName(java.nio.ByteBuffer rowKey,
                                                  IColumn column)
Specified by:
makeIndexColumnName in class AbstractSimplePerColumnSecondaryIndex

createSecondaryIndexSearcher

public SecondaryIndexSearcher createSecondaryIndexSearcher(java.util.Set<java.nio.ByteBuffer> columns)
Description copied from class: SecondaryIndex
Called at query time Creates a implementation specific searcher instance for this index type

Specified by:
createSecondaryIndexSearcher in class SecondaryIndex
Parameters:
columns - the list of columns which belong to this index type
Returns:
the secondary index search impl

validateOptions

public void validateOptions()
                     throws ConfigurationException
Description copied from class: SecondaryIndex
Validates the index_options passed in the ColumnDef

Specified by:
validateOptions in class SecondaryIndex
Throws:
ConfigurationException

getExpressionComparator

protected AbstractType getExpressionComparator()
Specified by:
getExpressionComparator in class AbstractSimplePerColumnSecondaryIndex


Copyright © 2013 The Apache Software Foundation