Class QueryResults
- All Implemented Interfaces:
- Serializable,- Iterable<QueryResults.Row>,- Collection<QueryResults.Row>,- List<QueryResults.Row>
This object represents the results of a query / nested query structure generated by a report's query datasource. The query results are stored in the "coreResults" dataset field, and any nested queries are stored in a map of dataKey -> QueryResults
It is constructed to be java.io.serializable and reportmill-friendly (meaning, it is a java.util.List<RMKey.Get>) Created by carl.gould on 2/3/2015.
- See Also:
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionclassEach row implements RMKey.Get, which knows how to retrieve a value based on column name
- 
Field SummaryFields inherited from class java.util.AbstractListmodCount
- 
Constructor SummaryConstructorsConstructorDescriptionQueryResults(Dataset dataset) Create a new QueryResults with the results of a queryQueryResults(Dataset dataset, QueryResults parent, int parentRow) 
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddNestedQueryResults(String key, QueryResults[] results) Add results from a nested query.get(int index) Get the results of the "core" query that created this object.Get the nested query resultsintsize()Methods inherited from class java.util.AbstractListadd, add, addAll, clear, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subListMethods inherited from class java.util.AbstractCollectionaddAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toStringMethods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.CollectionparallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.ListaddAll, contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray
- 
Constructor Details- 
QueryResults
- 
QueryResultsCreate a new QueryResults with the results of a query
 
- 
- 
Method Details- 
getCoreResultsGet the results of the "core" query that created this object. Doesn't include nested queries
- 
getNestedQueryResultsGet the nested query results
- 
addNestedQueryResultsAdd results from a nested query. The length of the results array should match the size() of this list, which is the row length of the core results dataset
- 
get- Specified by:
- getin interface- List<QueryResults.Row>
- Specified by:
- getin class- AbstractList<QueryResults.Row>
 
- 
sizepublic int size()- Specified by:
- sizein interface- Collection<QueryResults.Row>
- Specified by:
- sizein interface- List<QueryResults.Row>
- Specified by:
- sizein class- AbstractCollection<QueryResults.Row>
 
- 
lookup
 
-