public abstract class AbstractQuery<T extends Query<?,?>,U> extends ListQueryParameterObject implements Command<Object>, Query<T,U>, Serializable
| Modifier and Type | Class and Description |
|---|---|
static class |
AbstractQuery.NullHandlingOnOrder |
| Modifier and Type | Field and Description |
|---|---|
protected CommandContext |
commandContext |
protected CommandExecutor |
commandExecutor |
protected String |
databaseType |
protected AbstractQuery.NullHandlingOnOrder |
nullHandlingOnOrder |
protected String |
orderBy |
protected QueryProperty |
orderProperty |
protected org.activiti.dmn.engine.impl.AbstractQuery.ResultType |
resultType |
static String |
SORTORDER_ASC |
static String |
SORTORDER_DESC |
firstResult, maxResults, parameter| Modifier | Constructor and Description |
|---|---|
protected |
AbstractQuery() |
|
AbstractQuery(CommandContext commandContext) |
protected |
AbstractQuery(CommandExecutor commandExecutor) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addOrder(String column,
String sortOrder,
AbstractQuery.NullHandlingOnOrder nullHandlingOnOrder) |
T |
asc() |
protected void |
checkQueryOk() |
long |
count() |
T |
desc() |
T |
direction(Direction direction) |
Object |
execute(CommandContext commandContext) |
abstract long |
executeCount(CommandContext commandContext) |
abstract List<U> |
executeList(CommandContext commandContext,
Page page)
Executes the actual query to retrieve the list of results.
|
U |
executeSingleResult(CommandContext commandContext) |
String |
getDatabaseType() |
String |
getOrderBy() |
String |
getOrderByColumns() |
List<U> |
list() |
List<U> |
listPage(int firstResult,
int maxResults) |
T |
orderBy(QueryProperty property) |
T |
orderBy(QueryProperty property,
AbstractQuery.NullHandlingOnOrder nullHandlingOnOrder) |
AbstractQuery<T,U> |
setCommandExecutor(CommandExecutor commandExecutor) |
void |
setDatabaseType(String databaseType) |
U |
singleResult() |
getFirstResult, getFirstRow, getLastRow, getMaxResults, getParameter, setFirstResult, setMaxResults, setParameterpublic static final String SORTORDER_ASC
public static final String SORTORDER_DESC
protected transient CommandExecutor commandExecutor
protected transient CommandContext commandContext
protected String databaseType
protected String orderBy
protected org.activiti.dmn.engine.impl.AbstractQuery.ResultType resultType
protected QueryProperty orderProperty
protected AbstractQuery.NullHandlingOnOrder nullHandlingOnOrder
protected AbstractQuery()
protected AbstractQuery(CommandExecutor commandExecutor)
public AbstractQuery(CommandContext commandContext)
public AbstractQuery<T,U> setCommandExecutor(CommandExecutor commandExecutor)
public T orderBy(QueryProperty property)
public T orderBy(QueryProperty property, AbstractQuery.NullHandlingOnOrder nullHandlingOnOrder)
protected void checkQueryOk()
public U singleResult()
singleResult in interface Query<T extends Query<?,?>,U>public Object execute(CommandContext commandContext)
public abstract long executeCount(CommandContext commandContext)
public abstract List<U> executeList(CommandContext commandContext, Page page)
page - used if the results must be paged. If null, no paging will be applied.public U executeSingleResult(CommandContext commandContext)
protected void addOrder(String column, String sortOrder, AbstractQuery.NullHandlingOnOrder nullHandlingOnOrder)
public String getOrderBy()
getOrderBy in class ListQueryParameterObjectpublic String getOrderByColumns()
getOrderByColumns in class ListQueryParameterObjectpublic String getDatabaseType()
getDatabaseType in class ListQueryParameterObjectpublic void setDatabaseType(String databaseType)
setDatabaseType in class ListQueryParameterObjectCopyright © 2017 Alfresco. All rights reserved.