| Modifier and Type | Class and Description |
|---|---|
(package private) static class |
ListQueryImpl.IteratorAdapter<E,T> |
| Constructor and Description |
|---|
ListQueryImpl(AbstractSelectStatement<E,?,T> statement,
String sql,
QueryMode mode,
Function<T,E> mapper)
The constructor.
|
| Modifier and Type | Method and Description |
|---|---|
List<E> |
execute()
|
protected Function<T,E> |
getMapper() |
Iterator<E> |
iterator()
|
private Iterator<T> |
iteratorInternal() |
executeInternal, getMode, getSql, getStatement, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEach, spliteratorpublic ListQueryImpl(AbstractSelectStatement<E,?,T> statement, String sql, QueryMode mode, Function<T,E> mapper)
statement - the AbstractSelectStatement that created this
Query.sql - the SQL of the statement.mode - the QueryMode.mapper - the Function to map the results.public Iterator<E> iterator()
ListQueryExecutes the query and returns the matching objects as Iterator. This method may be
overridden for database technology implementations that have native support for Iterator (unlike JPA). In
such case this method is way more efficient if you only need to iterate the results to a specific point without the
need to know the number of matches. If possible you shall prefer this method over
Query.execute().Copyright © 2001–2016 mmm-Team. All rights reserved.