Class GoogleSheetsRangeBuilder
java.lang.Object
org.apache.drill.exec.store.googlesheets.utils.GoogleSheetsRangeBuilder
This class is used to construct a range with the GoogleSheet reader in Drill. This
builder generates ranges and can apply the projection and limit pushdowns to the ranges.
GoogleSheets uses A1 notation for defining columns and ranges. An example would be:
'Sheet1'!A11:F20
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddColumn
(int columnIndex) addFirstColumn
(String column) addLastColumn
(String column) addLimit
(int limit) Adds a limit to the range builder.addProjectedRanges
(List<GoogleSheetsColumnRange> projectedRanges) addRowCount
(int rowCount) int
boolean
hasNext()
isStarQuery
(boolean isStarQuery) void
When a limit is not present, the BatchReader must call this method to indicate when there are no more results and to stop generating new ranges.next()
toString()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Iterator
forEachRemaining, remove
-
Constructor Details
-
GoogleSheetsRangeBuilder
-
-
Method Details
-
addColumn
-
addColumn
-
addLimit
Adds a limit to the range builder.- Parameters:
limit
- The maximum number of total results returned- Returns:
- The range builder with the limit applied
-
addFirstColumn
-
addLastColumn
-
addRowCount
-
addProjectedRanges
-
isStarQuery
-
lastBatch
public void lastBatch()When a limit is not present, the BatchReader must call this method to indicate when there are no more results and to stop generating new ranges. -
hasNext
public boolean hasNext() -
next
-
nextBatch
-
getRowCount
public int getRowCount() -
toString
-