public class Results extends Object implements QueryResults
QueryResults.Columns, QueryResults.Statistics| Modifier and Type | Field and Description |
|---|---|
static Results |
EMPTY |
FORMATTER| Constructor and Description |
|---|
Results(QueryResults.Columns columns,
QueryResults.Statistics statistics,
NodeSequence rows,
CachedNodeSupplier cachedNodes,
Problems problems,
String plan)
Create a results object for the supplied context, command, and result columns and with the supplied tuples.
|
| Modifier and Type | Method and Description |
|---|---|
CachedNodeSupplier |
getCachedNodes()
Get the supplier with which a node can be found by key.
|
QueryResults.Columns |
getColumns()
Get the description of the columns contained in these results.
|
String |
getPlan()
Get a description of the query plan, if requested.
|
Problems |
getProblems()
Get the problems encountered during execution.
|
long |
getRowCount()
Get the number of rows in the results, if that information is available.
|
NodeSequence |
getRows()
Get the rows that make up these query results.
|
QueryResults.Statistics |
getStatistics()
Get the statistics that describe the time metrics for this query.
|
boolean |
hasErrors()
Return true if there is at least one error recorded in the
problems. |
boolean |
hasWarnings()
Return true if there is at least one warning recorded in the
problems. |
boolean |
isEmpty()
Determine whether this results is known to be empty.
|
String |
toString() |
String |
toString(TypeSystem typeSystem,
int maxTuples)
Get a string representation of this result object, with a maximum number of tuples to include.
|
void |
toString(TypeSystem typeSystem,
StringBuilder sb)
Get a string representation of this result object.
|
void |
toString(TypeSystem typeSystem,
StringBuilder sb,
int maxTuples)
Get a string representation of this result object, with a maximum number of tuples to include.
|
public static final Results EMPTY
public Results(QueryResults.Columns columns, QueryResults.Statistics statistics, NodeSequence rows, CachedNodeSupplier cachedNodes, Problems problems, String plan)
columns - the definition of the query result columnsstatistics - the statistics for this query; may not be nullrows - the sequence of rows; may not be nullcachedNodes - the supplier for obtaining cached nodes; may not be nullproblems - the problems; may be null if there are no problemsplan - the text representation of the query plan, if the hints asked for itpublic CachedNodeSupplier getCachedNodes()
QueryResultsgetCachedNodes in interface QueryResultsCachedNode instances; never nullpublic QueryResults.Columns getColumns()
QueryResultsgetColumns in interface QueryResultspublic NodeSequence getRows()
QueryResultsgetRows in interface QueryResultspublic long getRowCount()
QueryResultsgetRowCount in interface QueryResultspublic boolean isEmpty()
QueryResultsisEmpty in interface QueryResultspublic String getPlan()
QueryResultsgetPlan in interface QueryResultspublic Problems getProblems()
QueryResultsgetProblems in interface QueryResultspublic boolean hasErrors()
QueryResultsproblems.hasErrors in interface QueryResultspublic boolean hasWarnings()
QueryResultsproblems.hasWarnings in interface QueryResultspublic QueryResults.Statistics getStatistics()
QueryResultsgetStatistics in interface QueryResultspublic String toString(TypeSystem typeSystem, int maxTuples)
typeSystem - the type system that can be used to convert the values to a string; may be null if
Object.toString() should be usedmaxTuples - the maximum number of tuples to print, or Integer.MAX_VALUE if all the tuples are to be printedpublic void toString(TypeSystem typeSystem, StringBuilder sb)
typeSystem - the type system that can be used to convert the values to a string; may be null if
Object.toString() should be usedsb - the string builder to which the results should be written; may not be nullpublic void toString(TypeSystem typeSystem, StringBuilder sb, int maxTuples)
typeSystem - the type system that can be used to convert the values to a string; may be null if
Object.toString() should be usedsb - the string builder to which the results should be written; may not be nullmaxTuples - the maximum number of tuples to print, or Integer.MAX_VALUE if all the tuples are to be printedCopyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.