Interface RowReader
- All Superinterfaces:
AutoCloseable
- All Known Implementing Classes:
BitSetRowReader
Zero-copy columnar cursor for iterating over graph query results.
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidclose()intReturns the total number of columns in the result set.getColumnName(int columnIndex) Returns the name of the column at the given 0-indexed position.doublegetDouble(int columnIndex) Obtains the double-precision float at the given 0-indexed column.doubleObtains the double-precision float for the given column name.longgetLong(int columnIndex) Obtains the 64-bit integer at the given 0-indexed column.longObtains the 64-bit integer for the given column name.longgetNodeId(int columnIndex) Obtains the dense node ID at the given 0-indexed column.longObtains the dense node ID for the given column name.getString(int columnIndex) Obtains the string value at the given 0-indexed column.Obtains the string value for the given column name.booleannext()Advances cursor to the next row.longrowCount()Returns total row count if known, or -1.stream()Returns a sequential stream of rows for terminal consumption.
-
Method Details
-
next
boolean next()Advances cursor to the next row.- Returns:
- true if another row exists; false if iteration is complete
-
getNodeId
long getNodeId(int columnIndex) Obtains the dense node ID at the given 0-indexed column. -
getNodeId
Obtains the dense node ID for the given column name. -
getLong
long getLong(int columnIndex) Obtains the 64-bit integer at the given 0-indexed column. -
getLong
Obtains the 64-bit integer for the given column name. -
getDouble
double getDouble(int columnIndex) Obtains the double-precision float at the given 0-indexed column. -
getDouble
Obtains the double-precision float for the given column name. -
getString
Obtains the string value at the given 0-indexed column. -
getString
-
getColumnCount
int getColumnCount()Returns the total number of columns in the result set. -
getColumnName
Returns the name of the column at the given 0-indexed position. -
rowCount
long rowCount()Returns total row count if known, or -1. -
stream
Returns a sequential stream of rows for terminal consumption.WARNING: The RowReader instance is a mutable flyweight cursor. Do NOT collect the raw RowReader instances into a list or use parallel streams, as they will all reference the mutated state. Instead, map the row to an immutable record/DTO immediately within the stream pipeline.
Filtering should ideally be done natively via the VM query instead of client-side stream filters.
-
close
default void close()- Specified by:
closein interfaceAutoCloseable
-