@InterfaceStability.Committed
@InterfaceAudience.Public
public interface ViewResult
Represents the result from a ViewQuery.
| Modifier and Type | Method and Description |
|---|---|
java.util.List<ViewRow> |
allRows()
Collects all rows received from the view with the default view timeout.
|
java.util.List<ViewRow> |
allRows(long timeout,
java.util.concurrent.TimeUnit timeUnit)
Collects all rows received from the view with the default view timeout.
|
JsonObject |
debug()
If debug was enabled on the query, it is contained here.
|
JsonObject |
error()
If it was not successful, an error is contained here.
|
java.util.Iterator<ViewRow> |
rows()
Emits one
ViewRow for each row received from the view with the default view timeout. |
java.util.Iterator<ViewRow> |
rows(long timeout,
java.util.concurrent.TimeUnit timeUnit)
Emits one
ViewRow for each row received from the view with a custom timeout. |
boolean |
success()
If the query was successful.
|
int |
totalRows()
The total number of rows.
|
java.util.List<ViewRow> allRows()
Collects all rows received from the view with the default view timeout.
This method throws:
List containing view rows.java.util.List<ViewRow> allRows(long timeout, java.util.concurrent.TimeUnit timeUnit)
Collects all rows received from the view with the default view timeout.
This method throws:
List containing view rows.java.util.Iterator<ViewRow> rows()
Emits one ViewRow for each row received from the view with the default view timeout.
This method throws:
Iterator containing view rows.java.util.Iterator<ViewRow> rows(long timeout, java.util.concurrent.TimeUnit timeUnit)
Emits one ViewRow for each row received from the view with a custom timeout.
This method throws:
timeout - the custom timeout.timeUnit - the time unit for the custom timeout.Iterator containing view rows.int totalRows()
The total number of rows.
boolean success()
If the query was successful.
JsonObject error()
If it was not successful, an error is contained here.
JsonObject debug()
If debug was enabled on the query, it is contained here.