com.google.cloud.bigtable.grpc.scanner
Interface ResultScanner<T>
-
- Type Parameters:
T
- The type of Rows this scanner will iterate over. Expected Bigtable Row objects.
- All Superinterfaces:
- AutoCloseable, Closeable
- All Known Implementing Classes:
- ResumingStreamingResultScanner, RowResultScanner
public interface ResultScanner<T> extends Closeable
A scanner of Bigtable rows.- Version:
- $Id: $Id
- Author:
- sduskis
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description int
available()
Check number of rows immediately available.T
next()
Read the next row and block until a row is available.T[]
next(int count)
Read the next N rows where N <= count.
-
-
-
Method Detail
-
next
T next() throws IOException
Read the next row and block until a row is available. Will return null on end-of-stream.- Returns:
- a T object.
- Throws:
IOException
- if any.
-
next
T[] next(int count) throws IOException
Read the next N rows where N <= count. Will block until count are available or end-of-stream is reached.- Parameters:
count
- The number of rows to read.- Returns:
- an array of T objects.
- Throws:
IOException
- if any.
-
available
int available()
Check number of rows immediately available. Calls tonext()
will not block on network for at least n results.- Returns:
- a int.
-
-