org.apache.hadoop.hbase.util
Class Bytes.RowEndKeyComparator

java.lang.Object
  extended by org.apache.hadoop.hbase.util.Bytes.ByteArrayComparator
      extended by org.apache.hadoop.hbase.util.Bytes.RowEndKeyComparator
All Implemented Interfaces:
Comparator<byte[]>, org.apache.hadoop.io.RawComparator<byte[]>
Enclosing class:
Bytes

@InterfaceAudience.Public
@InterfaceStability.Stable
public static class Bytes.RowEndKeyComparator
extends Bytes.ByteArrayComparator

A Bytes.ByteArrayComparator that treats the empty array as the largest value. This is useful for comparing row end keys for regions.


Constructor Summary
Bytes.RowEndKeyComparator()
           
 
Method Summary
 int compare(byte[] left, byte[] right)
           
 int compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2)
           
 
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

Bytes.RowEndKeyComparator

public Bytes.RowEndKeyComparator()
Method Detail

compare

public int compare(byte[] left,
                   byte[] right)
Specified by:
compare in interface Comparator<byte[]>
Overrides:
compare in class Bytes.ByteArrayComparator

compare

public int compare(byte[] b1,
                   int s1,
                   int l1,
                   byte[] b2,
                   int s2,
                   int l2)
Specified by:
compare in interface org.apache.hadoop.io.RawComparator<byte[]>
Overrides:
compare in class Bytes.ByteArrayComparator


Copyright © 2007-2015 The Apache Software Foundation. All Rights Reserved.