blob: 3d015ef8537ca91b24e5b08e79cf85408864d23c [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>CellComparator (Apache HBase 3.0.0-alpha-2-SNAPSHOT API)</title>
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="CellComparator (Apache HBase 3.0.0-alpha-2-SNAPSHOT API)";
}
}
catch(err) {
}
//-->
var methods = {"i0":6,"i1":6,"i2":6,"i3":6,"i4":18,"i5":18,"i6":6,"i7":6,"i8":6,"i9":6,"i10":6,"i11":17,"i12":6};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"],16:["t5","Default Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/CellComparator.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/apache/hadoop/hbase/CellBuilderType.html" title="enum in org.apache.hadoop.hbase"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../org/apache/hadoop/hbase/CellScannable.html" title="interface in org.apache.hadoop.hbase"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/hadoop/hbase/CellComparator.html" target="_top">Frames</a></li>
<li><a href="CellComparator.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.hadoop.hbase</div>
<h2 title="Interface CellComparator" class="title">Interface CellComparator</h2>
</div>
<div class="contentContainer">
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Superinterfaces:</dt>
<dd><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</a>&lt;<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&gt;</dd>
</dl>
<hr>
<br>
<pre>@InterfaceAudience.Public
@InterfaceStability.Evolving
public interface <a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.33">CellComparator</a>
extends <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</a>&lt;<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&gt;</pre>
<div class="block">Comparator for comparing cells and has some specialized methods that allows comparing individual
cell components like row, family, qualifier and timestamp</div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t5" class="tableTab"><span><a href="javascript:show(16);">Default Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compare-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">compare</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</code>
<div class="block">Lexographically compares two cells.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compare-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-boolean-">compare</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell,
boolean&nbsp;ignoreSequenceid)</code>
<div class="block">Compare cells.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareFamilies-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">compareFamilies</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</code>
<div class="block">Lexographically compares the families of the two cells</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareQualifiers-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">compareQualifiers</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</code>
<div class="block">Lexographically compares the qualifiers of the two cells</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>default int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareRows-byte:A-byte:A-">compareRows</a></span>(byte[]&nbsp;leftRow,
byte[]&nbsp;rightRow)</code>
<div class="block">Compares two row bytes</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>default int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareRows-java.nio.ByteBuffer-org.apache.hadoop.hbase.Cell-">compareRows</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a>&nbsp;row,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;cell)</code>&nbsp;</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareRows-org.apache.hadoop.hbase.Cell-byte:A-int-int-">compareRows</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;cell,
byte[]&nbsp;bytes,
int&nbsp;offset,
int&nbsp;length)</code>
<div class="block">Compares the row part of the cell with a simple plain byte[] like the
stopRow in Scan.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareRows-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">compareRows</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</code>
<div class="block">Lexographically compares the rows of two cells.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareTimestamps-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">compareTimestamps</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</code>
<div class="block">Compares cell's timestamps in DESCENDING order.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareTimestamps-long-long-">compareTimestamps</a></span>(long&nbsp;leftCellts,
long&nbsp;rightCellts)</code>
<div class="block">Compares cell's timestamps in DESCENDING order.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#compareWithoutRow-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">compareWithoutRow</a></span>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</code>
<div class="block">Lexographically compares the two cells excluding the row part.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>static <a href="../../../../org/apache/hadoop/hbase/CellComparator.html" title="interface in org.apache.hadoop.hbase">CellComparator</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#getInstance--">getInstance</a></span>()</code>
<div class="block">A comparator for ordering cells in user-space tables.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/hadoop/hbase/CellComparator.html#getSimpleComparator--">getSimpleComparator</a></span>()</code>&nbsp;</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.util.Comparator">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;java.util.<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</a></h3>
<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#comparing-java.util.function.Function-" title="class or interface in java.util">comparing</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#comparing-java.util.function.Function-java.util.Comparator-" title="class or interface in java.util">comparing</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#comparingDouble-java.util.function.ToDoubleFunction-" title="class or interface in java.util">comparingDouble</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#comparingInt-java.util.function.ToIntFunction-" title="class or interface in java.util">comparingInt</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#comparingLong-java.util.function.ToLongFunction-" title="class or interface in java.util">comparingLong</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.util">equals</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#naturalOrder--" title="class or interface in java.util">naturalOrder</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#nullsFirst-java.util.Comparator-" title="class or interface in java.util">nullsFirst</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#nullsLast-java.util.Comparator-" title="class or interface in java.util">nullsLast</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#reversed--" title="class or interface in java.util">reversed</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#reverseOrder--" title="class or interface in java.util">reverseOrder</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#thenComparing-java.util.Comparator-" title="class or interface in java.util">thenComparing</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#thenComparing-java.util.function.Function-" title="class or interface in java.util">thenComparing</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#thenComparing-java.util.function.Function-java.util.Comparator-" title="class or interface in java.util">thenComparing</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#thenComparingDouble-java.util.function.ToDoubleFunction-" title="class or interface in java.util">thenComparingDouble</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#thenComparingInt-java.util.function.ToIntFunction-" title="class or interface in java.util">thenComparingInt</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#thenComparingLong-java.util.function.ToLongFunction-" title="class or interface in java.util">thenComparingLong</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="getInstance--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getInstance</h4>
<pre>static&nbsp;<a href="../../../../org/apache/hadoop/hbase/CellComparator.html" title="interface in org.apache.hadoop.hbase">CellComparator</a>&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.42">getInstance</a>()</pre>
<div class="block">A comparator for ordering cells in user-space tables. Useful when writing cells in sorted
order as necessary for bulk import (i.e. via MapReduce).
<p>
CAUTION: This comparator may provide inaccurate ordering for cells from system tables,
and should not be relied upon in that case.</div>
</li>
</ul>
<a name="compare-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compare</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.55">compare</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</pre>
<div class="block">Lexographically compares two cells. The key part of the cell is taken for comparison which
includes row, family, qualifier, timestamp and type</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true#compare-T-T-" title="class or interface in java.util">compare</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</a>&lt;<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&gt;</code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCell</code> - the left hand side cell</dd>
<dd><code>rightCell</code> - the right hand side cell</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compare-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compare</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.63">compare</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell,
boolean&nbsp;ignoreSequenceid)</pre>
<div class="block">Compare cells.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>ignoreSequenceid</code> - True if we are to compare the key portion only and ignore
the sequenceid. Set to false to compare key and consider sequenceid.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>0 if equal, -1 if a &lt; b, and +1 if a &gt; b.</dd>
</dl>
</li>
</ul>
<a name="compareRows-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareRows</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.72">compareRows</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</pre>
<div class="block">Lexographically compares the rows of two cells.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCell</code> - the left hand side cell</dd>
<dd><code>rightCell</code> - the right hand side cell</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compareRows-org.apache.hadoop.hbase.Cell-byte:A-int-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareRows</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.84">compareRows</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;cell,
byte[]&nbsp;bytes,
int&nbsp;offset,
int&nbsp;length)</pre>
<div class="block">Compares the row part of the cell with a simple plain byte[] like the
stopRow in Scan.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cell</code> - the cell</dd>
<dd><code>bytes</code> - the byte[] representing the row to be compared with</dd>
<dd><code>offset</code> - the offset of the byte[]</dd>
<dd><code>length</code> - the length of the byte[]</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compareRows-byte:A-byte:A-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareRows</h4>
<pre>default&nbsp;int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.93">compareRows</a>(byte[]&nbsp;leftRow,
byte[]&nbsp;rightRow)</pre>
<div class="block">Compares two row bytes</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftRow</code> - the byte array of the left row</dd>
<dd><code>rightRow</code> - the byte array of the right row</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftRow is bigger, less than 0 if rightRow is bigger, 0 if both
rows are equal</dd>
</dl>
</li>
</ul>
<a name="compareRows-java.nio.ByteBuffer-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareRows</h4>
<pre>default&nbsp;int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.103">compareRows</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a>&nbsp;row,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;cell)</pre>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>row</code> - ByteBuffer that wraps a row; will read from current position and will reading all
remaining; will not disturb the ByteBuffer internal state.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compareWithoutRow-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareWithoutRow</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.123">compareWithoutRow</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</pre>
<div class="block">Lexographically compares the two cells excluding the row part. It compares family, qualifier,
timestamp and the type</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCell</code> - the left hand side cell</dd>
<dd><code>rightCell</code> - the right hand side cell</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compareFamilies-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareFamilies</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.132">compareFamilies</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</pre>
<div class="block">Lexographically compares the families of the two cells</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCell</code> - the left hand side cell</dd>
<dd><code>rightCell</code> - the right hand side cell</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compareQualifiers-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareQualifiers</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.141">compareQualifiers</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</pre>
<div class="block">Lexographically compares the qualifiers of the two cells</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCell</code> - the left hand side cell</dd>
<dd><code>rightCell</code> - the right hand side cell</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
cells are equal</dd>
</dl>
</li>
</ul>
<a name="compareTimestamps-org.apache.hadoop.hbase.Cell-org.apache.hadoop.hbase.Cell-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareTimestamps</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.153">compareTimestamps</a>(<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;leftCell,
<a href="../../../../org/apache/hadoop/hbase/Cell.html" title="interface in org.apache.hadoop.hbase">Cell</a>&nbsp;rightCell)</pre>
<div class="block">Compares cell's timestamps in DESCENDING order. The below older timestamps sorting ahead of
newer timestamps looks wrong but it is intentional. This way, newer timestamps are first found
when we iterate over a memstore and newer versions are the first we trip over when reading from
a store file.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCell</code> - the left hand side cell</dd>
<dd><code>rightCell</code> - the right hand side cell</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>1 if left's timestamp &lt; right's timestamp -1 if left's timestamp &gt; right's
timestamp 0 if both timestamps are equal</dd>
</dl>
</li>
</ul>
<a name="compareTimestamps-long-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareTimestamps</h4>
<pre>int&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.165">compareTimestamps</a>(long&nbsp;leftCellts,
long&nbsp;rightCellts)</pre>
<div class="block">Compares cell's timestamps in DESCENDING order. The below older timestamps sorting ahead of
newer timestamps looks wrong but it is intentional. This way, newer timestamps are first found
when we iterate over a memstore and newer versions are the first we trip over when reading from
a store file.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>leftCellts</code> - the left cell's timestamp</dd>
<dd><code>rightCellts</code> - the right cell's timestamp</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>1 if left's timestamp &lt; right's timestamp -1 if left's timestamp &gt; right's
timestamp 0 if both timestamps are equal</dd>
</dl>
</li>
</ul>
<a name="getSimpleComparator--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getSimpleComparator</h4>
<pre><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</a>&nbsp;<a href="../../../../src-html/org/apache/hadoop/hbase/CellComparator.html#line.172">getSimpleComparator</a>()</pre>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>A dumbed-down, fast comparator for hbase2 base-type, the <code>ByteBufferKeyValue</code>.
Create an instance when you make a new memstore, when you know only BBKVs will be passed.
Do not pollute with types other than BBKV if can be helped; the Comparator will slow.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/CellComparator.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/apache/hadoop/hbase/CellBuilderType.html" title="enum in org.apache.hadoop.hbase"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../org/apache/hadoop/hbase/CellScannable.html" title="interface in org.apache.hadoop.hbase"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/hadoop/hbase/CellComparator.html" target="_top">Frames</a></li>
<li><a href="CellComparator.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &#169; 2007&#x2013;2021 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
</body>
</html>