Package org.activiti.engine.query
Interface Query<T extends Query<?,?>,U>
- All Known Subinterfaces:
DeadLetterJobQuery,DeploymentQuery,ExecutionQuery,HistoricActivityInstanceQuery,HistoricDetailQuery,HistoricProcessInstanceQuery,HistoricTaskInstanceQuery,HistoricVariableInstanceQuery,JobQuery,ModelQuery,ProcessDefinitionQuery,ProcessInstanceQuery,SuspendedJobQuery,TaskInfoQuery<T,,V> TaskQuery,TimerJobQuery
- All Known Implementing Classes:
AbstractQuery,AbstractVariableQueryImpl,DeadLetterJobQueryImpl,DeploymentQueryImpl,EventSubscriptionQueryImpl,ExecutionQueryImpl,HistoricActivityInstanceQueryImpl,HistoricDetailQueryImpl,HistoricProcessInstanceQueryImpl,HistoricTaskInstanceQueryImpl,HistoricVariableInstanceQueryImpl,JobQueryImpl,ModelQueryImpl,ProcessDefinitionQueryImpl,ProcessInstanceQueryImpl,SuspendedJobQueryImpl,TaskQueryImpl,TimerJobQueryImpl
Describes basic methods for querying.
-
Method Summary
Modifier and TypeMethodDescriptionasc()Order the results ascending on the given property as defined in this class (needs to come after a call to one of the orderByXxxx methods).longcount()Executes the query and returns the number of resultsdesc()Order the results descending on the given property as defined in this class (needs to come after a call to one of the orderByXxxx methods).list()Executes the query and get a list of entities as the result.listPage(int firstResult, int maxResults) Executes the query and get a list of entities as the result.orderBy(QueryProperty property) Executes the query and returns the resulting entity or null if no entity matches the query criteria.
-
Method Details
-
asc
T asc()Order the results ascending on the given property as defined in this class (needs to come after a call to one of the orderByXxxx methods). -
desc
T desc()Order the results descending on the given property as defined in this class (needs to come after a call to one of the orderByXxxx methods). -
orderBy
- Parameters:
property- theQueryPropertyto be used to order the results- Returns:
- itself
-
count
long count()Executes the query and returns the number of results -
singleResult
U singleResult()Executes the query and returns the resulting entity or null if no entity matches the query criteria.- Throws:
ActivitiException- when the query results in more than one entities.
-
list
Executes the query and get a list of entities as the result. -
listPage
Executes the query and get a list of entities as the result.
-