Package org.camunda.bpm.engine.query
Interface Query<T extends Query<?,?>,U>
- All Known Subinterfaces:
ActivityStatisticsQuery
,AuthorizationQuery
,BatchQuery
,BatchStatisticsQuery
,CaseDefinitionQuery
,CaseExecutionQuery
,CaseInstanceQuery
,CleanableHistoricBatchReport
,CleanableHistoricCaseInstanceReport
,CleanableHistoricDecisionInstanceReport
,CleanableHistoricProcessInstanceReport
,DecisionDefinitionQuery
,DecisionRequirementsDefinitionQuery
,DeploymentQuery
,DeploymentStatisticsQuery
,EventSubscriptionQuery
,ExecutionQuery
,ExternalTaskQuery
,FilterQuery
,GroupQuery
,HistoricActivityInstanceQuery
,HistoricActivityStatisticsQuery
,HistoricBatchQuery
,HistoricCaseActivityInstanceQuery
,HistoricCaseActivityStatisticsQuery
,HistoricCaseInstanceQuery
,HistoricDecisionInstanceQuery
,HistoricDecisionInstanceStatisticsQuery
,HistoricDetailQuery
,HistoricExternalTaskLogQuery
,HistoricIdentityLinkLogQuery
,HistoricIncidentQuery
,HistoricJobLogQuery
,HistoricProcessInstanceQuery
,HistoricTaskInstanceQuery
,HistoricVariableInstanceQuery
,IncidentQuery
,JobDefinitionQuery
,JobQuery
,ProcessDefinitionQuery
,ProcessDefinitionStatisticsQuery
,ProcessInstanceQuery
,SchemaLogQuery
,TaskQuery
,TenantQuery
,UserOperationLogQuery
,UserQuery
,VariableInstanceQuery
- All Known Implementing Classes:
AbstractQuery
,AbstractVariableQueryImpl
,ActivityStatisticsQueryImpl
,AuthorizationQueryImpl
,BatchQueryImpl
,BatchStatisticsQueryImpl
,CaseDefinitionQueryImpl
,CaseExecutionQueryImpl
,CaseInstanceQueryImpl
,CaseSentryPartQueryImpl
,CleanableHistoricBatchReportImpl
,CleanableHistoricCaseInstanceReportImpl
,CleanableHistoricDecisionInstanceReportImpl
,CleanableHistoricProcessInstanceReportImpl
,DbGroupQueryImpl
,DbTenantQueryImpl
,DbUserQueryImpl
,DecisionDefinitionQueryImpl
,DecisionRequirementsDefinitionQueryImpl
,DeploymentQueryImpl
,DeploymentStatisticsQueryImpl
,EventSubscriptionQueryImpl
,ExecutionQueryImpl
,ExternalTaskQueryImpl
,FilterQueryImpl
,GroupQueryImpl
,HistoricActivityInstanceQueryImpl
,HistoricActivityStatisticsQueryImpl
,HistoricBatchQueryImpl
,HistoricCaseActivityInstanceQueryImpl
,HistoricCaseActivityStatisticsQueryImpl
,HistoricCaseInstanceQueryImpl
,HistoricDecisionInstanceQueryImpl
,HistoricDecisionInstanceStatisticsQueryImpl
,HistoricDetailQueryImpl
,HistoricExternalTaskLogQueryImpl
,HistoricIdentityLinkLogQueryImpl
,HistoricIncidentQueryImpl
,HistoricJobLogQueryImpl
,HistoricProcessInstanceQueryImpl
,HistoricTaskInstanceQueryImpl
,HistoricVariableInstanceQueryImpl
,IncidentQueryImpl
,JobDefinitionQueryImpl
,JobQueryImpl
,LdapGroupQuery
,LdapTenantQuery
,LdapUserQueryImpl
,OAuth2IdentityProvider.OAuth2GroupQuery
,OAuth2IdentityProvider.OAuth2TenantQuery
,OAuth2IdentityProvider.OAuth2UserQuery
,ProcessDefinitionQueryImpl
,ProcessDefinitionStatisticsQueryImpl
,ProcessInstanceQueryImpl
,SchemaLogQueryImpl
,TaskQueryImpl
,TenantQueryImpl
,UserOperationLogQueryImpl
,UserQueryImpl
,VariableInstanceQueryImpl
public interface Query<T extends Query<?,?>,U>
Describes basic methods for querying.
- Author:
- Frederik Heremans
-
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).long
count()
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.Executes the query and returns the resulting entity or null if no entity matches the query criteria.Executes the query.
-
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). -
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:
ProcessEngineException
- when the query results in more than one entities.
-
list
Executes the query and get a list of entities as the result.- Returns:
- a list of results
- Throws:
BadUserRequestException
- When a maximum results limit is specified. A maximum results limit can be specified with the process engine configuration propertyqueryMaxResultsLimit
(defaultInteger.MAX_VALUE
). Please uselistPage(int, int)
instead.
-
unlimitedList
Executes the query. No limitation checks are performed (e. g. query limit).- Returns:
- a list of results
-
listPage
Executes the query and get a list of entities as the result.- Parameters:
firstResult
- the index of the first resultmaxResults
- the maximum number of results- Returns:
- a list of results
- Throws:
BadUserRequestException
- When exceeds the maximum results limit. A maximum results limit can be specified with the process engine configuration propertyqueryMaxResultsLimit
(defaultInteger.MAX_VALUE
).
-