org.apache.hadoop.hbase.client
Class ClientSideRegionScanner

java.lang.Object
  extended by org.apache.hadoop.hbase.client.AbstractClientScanner
      extended by org.apache.hadoop.hbase.client.ClientSideRegionScanner
All Implemented Interfaces:
Closeable, Iterable<Result>, ResultScanner

@InterfaceAudience.Private
public class ClientSideRegionScanner
extends AbstractClientScanner

A client scanner for a region opened for read-only on the client side. Assumes region data is not changing.


Field Summary
 
Fields inherited from class org.apache.hadoop.hbase.client.AbstractClientScanner
scanMetrics
 
Constructor Summary
ClientSideRegionScanner(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path rootDir, HTableDescriptor htd, HRegionInfo hri, Scan scan, ScanMetrics scanMetrics)
           
 
Method Summary
 void close()
          Closes the scanner and releases any resources it has allocated
 Result next()
          Grab the next row's worth of values.
 boolean renewLease()
          Allow the client to renew the scanner's lease on the server.
 
Methods inherited from class org.apache.hadoop.hbase.client.AbstractClientScanner
getScanMetrics, initScanMetrics, iterator, next
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClientSideRegionScanner

public ClientSideRegionScanner(org.apache.hadoop.conf.Configuration conf,
                               org.apache.hadoop.fs.FileSystem fs,
                               org.apache.hadoop.fs.Path rootDir,
                               HTableDescriptor htd,
                               HRegionInfo hri,
                               Scan scan,
                               ScanMetrics scanMetrics)
                        throws IOException
Throws:
IOException
Method Detail

next

public Result next()
            throws IOException
Description copied from interface: ResultScanner
Grab the next row's worth of values. The scanner will return a Result.

Returns:
Result object if there is another row, null if the scanner is exhausted.
Throws:
IOException - e

close

public void close()
Description copied from interface: ResultScanner
Closes the scanner and releases any resources it has allocated


renewLease

public boolean renewLease()
Description copied from class: AbstractClientScanner
Allow the client to renew the scanner's lease on the server.

Specified by:
renewLease in class AbstractClientScanner
Returns:
true if the lease was successfully renewed, false otherwise.


Copyright © 2015 The Apache Software Foundation. All rights reserved.