public abstract class FluentSelect<T> extends AbstractQuery implements Select<T>
ObjectSelect
and ColumnSelect
Modifier and Type | Field and Description |
---|---|
protected String |
dbEntityName |
protected String |
entityName |
protected Class<?> |
entityType |
protected Expression |
having |
protected Collection<Ordering> |
orderings |
protected Expression |
where |
root
logger
Modifier | Constructor and Description |
---|---|
protected |
FluentSelect() |
Modifier and Type | Method and Description |
---|---|
ResultBatchIterator<T> |
batchIterator(ObjectContext context,
int size)
Creates a ResultBatchIterator based on the provided context and batch
size.
|
SQLAction |
createSQLAction(SQLActionVisitor visitor)
A callback method invoked by Cayenne during the final execution phase of the query
run.
|
Collection<Property<?>> |
getColumns() |
String |
getDbEntityName() |
String |
getEntityName() |
Class<?> |
getEntityType() |
Expression |
getHaving()
Returns a HAVING clause Expression of this query.
|
int |
getLimit() |
int |
getOffset() |
Collection<Ordering> |
getOrderings() |
int |
getPageSize() |
PrefetchTreeNode |
getPrefetches() |
int |
getQueryTimeout() |
int |
getStatementFetchSize() |
Expression |
getWhere()
Returns a WHERE clause Expression of this query.
|
boolean |
isDistinct() |
boolean |
isFetchingDataRows() |
void |
iterate(ObjectContext context,
ResultIteratorCallback<T> callback)
Creates a ResultIterator based on the provided context and passes it to a
callback for processing.
|
ResultIterator<T> |
iterator(ObjectContext context)
Creates a ResultIterator based on the provided context.
|
protected Object |
resolveRoot(EntityResolver resolver) |
void |
route(QueryRouter router,
EntityResolver resolver,
Query substitutedQuery)
Implements default routing mechanism relying on the EntityResolver to find DataMap
based on the query root.
|
List<T> |
select(ObjectContext context)
Selects objects using provided context.
|
T |
selectOne(ObjectContext context)
Selects a single object using provided context.
|
getMetaData, getRoot, setRoot, toString
getBaseMetaData, getCacheGroup, getCacheStrategy, setCacheGroup, setCacheStrategy, useLocalCache, useLocalCache, useSharedCache, useSharedCache
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
selectFirst
getMetaData
protected Class<?> entityType
protected String entityName
protected String dbEntityName
protected Expression where
protected Expression having
protected Collection<Ordering> orderings
protected Object resolveRoot(EntityResolver resolver)
public int getStatementFetchSize()
public int getQueryTimeout()
public int getPageSize()
public int getLimit()
public int getOffset()
public Class<?> getEntityType()
public String getEntityName()
public String getDbEntityName()
public Expression getWhere()
public Expression getHaving()
public Collection<Ordering> getOrderings()
public PrefetchTreeNode getPrefetches()
public List<T> select(ObjectContext context)
Select
Essentially the inversion of "ObjectContext.select(Select)".
public T selectOne(ObjectContext context)
Select
CayenneRuntimeException
is thrown.
Essentially the inversion of "ObjectContext.selectOne(Select)".
public void iterate(ObjectContext context, ResultIteratorCallback<T> callback)
Select
Essentially the inversion of "ObjectContext.iterate(Select, ResultIteratorCallback)".
public ResultIterator<T> iterator(ObjectContext context)
Select
Select.iterate(ObjectContext, ResultIteratorCallback)
as an
alternative.
Essentially the inversion of "ObjectContext.iterator(Select)".
public ResultBatchIterator<T> batchIterator(ObjectContext context, int size)
Select
batchIterator
in interface Select<T>
public SQLAction createSQLAction(SQLActionVisitor visitor)
Query
createSQLAction
in interface Query
createSQLAction
in class AbstractQuery
public void route(QueryRouter router, EntityResolver resolver, Query substitutedQuery)
AbstractQuery
route
in interface Query
route
in class AbstractQuery
public boolean isFetchingDataRows()
public Collection<Property<?>> getColumns()
public boolean isDistinct()
Copyright © 2001–2020 Apache Cayenne. All rights reserved.