org.apache.hadoop.hbase.client.tableindexed
Class SimpleIndexKeyGenerator

java.lang.Object
  extended by org.apache.hadoop.hbase.client.tableindexed.SimpleIndexKeyGenerator
All Implemented Interfaces:
IndexKeyGenerator, org.apache.hadoop.io.Writable

public class SimpleIndexKeyGenerator
extends Object
implements IndexKeyGenerator

Creates indexed keys for a single column....


Constructor Summary
SimpleIndexKeyGenerator()
           
SimpleIndexKeyGenerator(byte[] column)
           
 
Method Summary
 byte[] createIndexKey(byte[] rowKey, Map<byte[],byte[]> columns)
          Create an index key from a base row.
 void readFields(DataInput in)
          
 void write(DataOutput out)
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleIndexKeyGenerator

public SimpleIndexKeyGenerator(byte[] column)

SimpleIndexKeyGenerator

public SimpleIndexKeyGenerator()
Method Detail

createIndexKey

public byte[] createIndexKey(byte[] rowKey,
                             Map<byte[],byte[]> columns)
Create an index key from a base row.

Specified by:
createIndexKey in interface IndexKeyGenerator
Parameters:
rowKey - the row key of the base row
columns - the columns in the base row
Returns:
the row key in the indexed row.

readFields

public void readFields(DataInput in)
                throws IOException

Specified by:
readFields in interface org.apache.hadoop.io.Writable
Throws:
IOException

write

public void write(DataOutput out)
           throws IOException

Specified by:
write in interface org.apache.hadoop.io.Writable
Throws:
IOException


Copyright © 2009 The Apache Software Foundation