blob: 5f31405168d8d9d67b39c465c00521b1c30a18bd [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 (1.8.0_292) on Tue Jun 15 06:01:51 GMT 2021 -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>TFile.Reader.Scanner (Apache Hadoop Common 3.3.1 API)</title>
<meta name="date" content="2021-06-15">
<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="TFile.Reader.Scanner (Apache Hadoop Common 3.3.1 API)";
}
}
catch(err) {
}
//-->
var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete 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/TFile.Reader.Scanner.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/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.Entry.html" title="class in org.apache.hadoop.io.file.tfile"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../../index.html?org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html" target="_top">Frames</a></li>
<li><a href="TFile.Reader.Scanner.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><a href="#nested.class.summary">Nested</a>&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&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><a href="#constructor.detail">Constr</a>&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.io.file.tfile</div>
<h2 title="Class TFile.Reader.Scanner" class="title">Class TFile.Reader.Scanner</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li>org.apache.hadoop.io.file.tfile.TFile.Reader.Scanner</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><a href="https://docs.oracle.com/javase/8/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/AutoCloseable.html?is-external=true" title="class or interface in java.lang">AutoCloseable</a></dd>
</dl>
<dl>
<dt>Enclosing class:</dt>
<dd><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader</a></dd>
</dl>
<hr>
<br>
<pre>public static class <span class="typeNameLabel">TFile.Reader.Scanner</span>
extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>
implements <a href="https://docs.oracle.com/javase/8/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a></pre>
<div class="block">The TFile Scanner. The Scanner has an implicit cursor, which, upon
creation, points to the first key-value pair in the scan range. If the
scan range is empty, the cursor will point to the end of the scan range.
<p>
Use <a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#atEnd--"><code>atEnd()</code></a> to test whether the cursor is at the end
location of the scanner.
<p>
Use <a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#advance--"><code>advance()</code></a> to move the cursor to the next key-value
pair (or end if none exists). Use seekTo methods (
<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#seekTo-byte:A-"><code>seekTo(byte[])</code></a> or
<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#seekTo-byte:A-int-int-"><code>seekTo(byte[], int, int)</code></a>) to seek to any arbitrary
location in the covered range (including backward seeking). Use
<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#rewind--"><code>rewind()</code></a> to seek back to the beginning of the scanner.
Use <a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#seekToEnd--"><code>seekToEnd()</code></a> to seek to the end of the scanner.
<p>
Actual keys and values may be obtained through <a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.Entry.html" title="class in org.apache.hadoop.io.file.tfile"><code>TFile.Reader.Scanner.Entry</code></a>
object, which is obtained through <a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#entry--"><code>entry()</code></a>.</div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== NESTED CLASS SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="nested.class.summary">
<!-- -->
</a>
<h3>Nested Class Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Nested Class Summary table, listing nested classes, and an explanation">
<caption><span>Nested Classes</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Class and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.Entry.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader.Scanner.Entry</a></span></code>
<div class="block">Entry to a &lt;Key, Value&gt; pair.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier</th>
<th class="colLast" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected </code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#Scanner-org.apache.hadoop.io.file.tfile.TFile.Reader-long-long-">Scanner</a></span>(<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader</a>&nbsp;reader,
long&nbsp;offBegin,
long&nbsp;offEnd)</code>
<div class="block">Constructor</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected </code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#Scanner-org.apache.hadoop.io.file.tfile.TFile.Reader-org.apache.hadoop.io.file.tfile.RawComparable-org.apache.hadoop.io.file.tfile.RawComparable-">Scanner</a></span>(<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader</a>&nbsp;reader,
<a href="../../../../../../org/apache/hadoop/io/file/tfile/RawComparable.html" title="interface in org.apache.hadoop.io.file.tfile">RawComparable</a>&nbsp;beginKey,
<a href="../../../../../../org/apache/hadoop/io/file/tfile/RawComparable.html" title="interface in org.apache.hadoop.io.file.tfile">RawComparable</a>&nbsp;endKey)</code>
<div class="block">Constructor</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== 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="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete 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>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#advance--">advance</a></span>()</code>
<div class="block">Move the cursor to the next key-value pair.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#atEnd--">atEnd</a></span>()</code>
<div class="block">Is cursor at the end location?</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#close--">close</a></span>()</code>
<div class="block">Close the scanner.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.Entry.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader.Scanner.Entry</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#entry--">entry</a></span>()</code>
<div class="block">Get an entry to access the key and value.</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#getRecordNum--">getRecordNum</a></span>()</code>
<div class="block">Get the RecordNum corresponding to the entry pointed by the cursor.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#lowerBound-byte:A-">lowerBound</a></span>(byte[]&nbsp;key)</code>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key.</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#lowerBound-byte:A-int-int-">lowerBound</a></span>(byte[]&nbsp;key,
int&nbsp;keyOffset,
int&nbsp;keyLen)</code>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#rewind--">rewind</a></span>()</code>
<div class="block">Rewind to the first entry in the scanner.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#seekTo-byte:A-">seekTo</a></span>(byte[]&nbsp;key)</code>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#seekTo-byte:A-int-int-">seekTo</a></span>(byte[]&nbsp;key,
int&nbsp;keyOffset,
int&nbsp;keyLen)</code>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#seekToEnd--">seekToEnd</a></span>()</code>
<div class="block">Seek to the end of the scanner.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#upperBound-byte:A-">upperBound</a></span>(byte[]&nbsp;key)</code>
<div class="block">Move the cursor to the first entry whose key is strictly greater than
the input key.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html#upperBound-byte:A-int-int-">upperBound</a></span>(byte[]&nbsp;key,
int&nbsp;keyOffset,
int&nbsp;keyLen)</code>
<div class="block">Move the cursor to the first entry whose key is strictly greater than
the input key.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="Scanner-org.apache.hadoop.io.file.tfile.TFile.Reader-long-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>Scanner</h4>
<pre>protected&nbsp;Scanner(<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader</a>&nbsp;reader,
long&nbsp;offBegin,
long&nbsp;offEnd)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Constructor</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>reader</code> - The TFile reader object.</dd>
<dd><code>offBegin</code> - Begin byte-offset of the scan.</dd>
<dd><code>offEnd</code> - End byte-offset of the scan.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - The offsets will be rounded to the beginning of a compressed
block whose offset is greater than or equal to the specified
offset.</dd>
</dl>
</li>
</ul>
<a name="Scanner-org.apache.hadoop.io.file.tfile.TFile.Reader-org.apache.hadoop.io.file.tfile.RawComparable-org.apache.hadoop.io.file.tfile.RawComparable-">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>Scanner</h4>
<pre>protected&nbsp;Scanner(<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader</a>&nbsp;reader,
<a href="../../../../../../org/apache/hadoop/io/file/tfile/RawComparable.html" title="interface in org.apache.hadoop.io.file.tfile">RawComparable</a>&nbsp;beginKey,
<a href="../../../../../../org/apache/hadoop/io/file/tfile/RawComparable.html" title="interface in org.apache.hadoop.io.file.tfile">RawComparable</a>&nbsp;endKey)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Constructor</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>reader</code> - The TFile reader object.</dd>
<dd><code>beginKey</code> - Begin key of the scan. If null, scan from the first
&lt;K, V&gt; entry of the TFile.</dd>
<dd><code>endKey</code> - End key of the scan. If null, scan up to the last &lt;K, V&gt;
entry of the TFile.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="seekTo-byte:A-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>seekTo</h4>
<pre>public&nbsp;boolean&nbsp;seekTo(byte[]&nbsp;key)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key. Synonymous to seekTo(key, 0, key.length). The entry
returned by the previous entry() call will be invalid.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - The input key</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true if we find an equal key.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="seekTo-byte:A-int-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>seekTo</h4>
<pre>public&nbsp;boolean&nbsp;seekTo(byte[]&nbsp;key,
int&nbsp;keyOffset,
int&nbsp;keyLen)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key. The entry returned by the previous entry() call will
be invalid.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - The input key</dd>
<dd><code>keyOffset</code> - offset in the key buffer.</dd>
<dd><code>keyLen</code> - key buffer length.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true if we find an equal key; false otherwise.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="rewind--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>rewind</h4>
<pre>public&nbsp;void&nbsp;rewind()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Rewind to the first entry in the scanner. The entry returned by the
previous entry() call will be invalid.</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="seekToEnd--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>seekToEnd</h4>
<pre>public&nbsp;void&nbsp;seekToEnd()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Seek to the end of the scanner. The entry returned by the previous
entry() call will be invalid.</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="lowerBound-byte:A-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>lowerBound</h4>
<pre>public&nbsp;void&nbsp;lowerBound(byte[]&nbsp;key)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key. Synonymous to lowerBound(key, 0, key.length). The
entry returned by the previous entry() call will be invalid.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - The input key</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="lowerBound-byte:A-int-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>lowerBound</h4>
<pre>public&nbsp;void&nbsp;lowerBound(byte[]&nbsp;key,
int&nbsp;keyOffset,
int&nbsp;keyLen)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the first entry whose key is greater than or equal
to the input key. The entry returned by the previous entry() call will
be invalid.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - The input key</dd>
<dd><code>keyOffset</code> - offset in the key buffer.</dd>
<dd><code>keyLen</code> - key buffer length.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="upperBound-byte:A-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>upperBound</h4>
<pre>public&nbsp;void&nbsp;upperBound(byte[]&nbsp;key)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the first entry whose key is strictly greater than
the input key. Synonymous to upperBound(key, 0, key.length). The entry
returned by the previous entry() call will be invalid.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - The input key</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="upperBound-byte:A-int-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>upperBound</h4>
<pre>public&nbsp;void&nbsp;upperBound(byte[]&nbsp;key,
int&nbsp;keyOffset,
int&nbsp;keyLen)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the first entry whose key is strictly greater than
the input key. The entry returned by the previous entry() call will be
invalid.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - The input key</dd>
<dd><code>keyOffset</code> - offset in the key buffer.</dd>
<dd><code>keyLen</code> - key buffer length.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="advance--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>advance</h4>
<pre>public&nbsp;boolean&nbsp;advance()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Move the cursor to the next key-value pair. The entry returned by the
previous entry() call will be invalid.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true if the cursor successfully moves. False when cursor is
already at the end location and cannot be advanced.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="close--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>close</h4>
<pre>public&nbsp;void&nbsp;close()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Close the scanner. Release all resources. The behavior of using the
scanner after calling close is not defined. The entry returned by the
previous entry() call will be invalid.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/Closeable.html?is-external=true#close--" title="class or interface in java.io">close</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</a></code></dd>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/AutoCloseable.html?is-external=true#close--" title="class or interface in java.lang">close</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/AutoCloseable.html?is-external=true" title="class or interface in java.lang">AutoCloseable</a></code></dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="atEnd--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>atEnd</h4>
<pre>public&nbsp;boolean&nbsp;atEnd()</pre>
<div class="block">Is cursor at the end location?</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true if the cursor is at the end location.</dd>
</dl>
</li>
</ul>
<a name="entry--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>entry</h4>
<pre>public&nbsp;<a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.Entry.html" title="class in org.apache.hadoop.io.file.tfile">TFile.Reader.Scanner.Entry</a>&nbsp;entry()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Get an entry to access the key and value.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The Entry object to access the key and value.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="getRecordNum--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getRecordNum</h4>
<pre>public&nbsp;long&nbsp;getRecordNum()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Get the RecordNum corresponding to the entry pointed by the cursor.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The RecordNum corresponding to the entry pointed by the cursor.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></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/TFile.Reader.Scanner.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/io/file/tfile/TFile.Reader.html" title="class in org.apache.hadoop.io.file.tfile"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../../../org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.Entry.html" title="class in org.apache.hadoop.io.file.tfile"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../../index.html?org/apache/hadoop/io/file/tfile/TFile.Reader.Scanner.html" target="_top">Frames</a></li>
<li><a href="TFile.Reader.Scanner.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><a href="#nested.class.summary">Nested</a>&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&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><a href="#constructor.detail">Constr</a>&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; 2008&#x2013;2021 <a href="https://www.apache.org">Apache Software Foundation</a>. All rights reserved.</small></p>
</body>
</html>