org.apache.hbase.cell
Class CellComparator

java.lang.Object
  extended by org.apache.hbase.cell.CellComparator
All Implemented Interfaces:
Serializable, Comparator<Cell>

@InterfaceAudience.Private
@InterfaceStability.Evolving
public class CellComparator
extends Object
implements Comparator<Cell>, Serializable

Compare two traditional HBase cells. Note: This comparator is not valid for -ROOT- and .META. tables.

See Also:
Serialized Form

Constructor Summary
CellComparator()
           
 
Method Summary
static boolean areKeyLengthsEqual(Cell a, Cell b)
          lengths
static boolean areRowLengthsEqual(Cell a, Cell b)
           
 int compare(Cell a, Cell b)
           
static int compareStatic(Cell a, Cell b)
           
static boolean equals(Cell a, Cell b)
          equals
static boolean equalsIgnoreMvccVersion(Cell a, Cell b)
          special case for KeyValue.equals
static boolean equalsRow(Cell a, Cell b)
           
static int hashCode(Cell cell)
          Returns a hash code that is always the same for two Cells having a matching equals(..) result.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

CellComparator

public CellComparator()
Method Detail

compare

public int compare(Cell a,
                   Cell b)
Specified by:
compare in interface Comparator<Cell>

compareStatic

public static int compareStatic(Cell a,
                                Cell b)

equals

public static boolean equals(Cell a,
                             Cell b)
equals


equalsRow

public static boolean equalsRow(Cell a,
                                Cell b)

hashCode

public static int hashCode(Cell cell)
Returns a hash code that is always the same for two Cells having a matching equals(..) result. Currently does not guard against nulls, but it could if necessary.


areKeyLengthsEqual

public static boolean areKeyLengthsEqual(Cell a,
                                         Cell b)
lengths


areRowLengthsEqual

public static boolean areRowLengthsEqual(Cell a,
                                         Cell b)

equalsIgnoreMvccVersion

public static boolean equalsIgnoreMvccVersion(Cell a,
                                              Cell b)
special case for KeyValue.equals



Copyright © 2013 The Apache Software Foundation. All Rights Reserved.