Class CaseDefinitionQueryImpl
- java.lang.Object
-
- org.camunda.bpm.engine.impl.db.ListQueryParameterObject
-
- org.camunda.bpm.engine.impl.AbstractQuery<CaseDefinitionQuery,CaseDefinition>
-
- org.camunda.bpm.engine.impl.cmmn.entity.repository.CaseDefinitionQueryImpl
-
- All Implemented Interfaces:
Serializable,Command<Object>,Query<CaseDefinitionQuery,CaseDefinition>,CaseDefinitionQuery
public class CaseDefinitionQueryImpl extends AbstractQuery<CaseDefinitionQuery,CaseDefinition> implements CaseDefinitionQuery
- Author:
- Roman Smirnov
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.camunda.bpm.engine.impl.AbstractQuery
AbstractQuery.ResultType
-
-
Field Summary
Fields Modifier and Type Field Description protected Stringcategoryprotected StringcategoryLikeprotected StringdeploymentIdprotected Stringidprotected String[]idsprotected booleanincludeDefinitionsWithoutTenantIdprotected booleanisTenantIdSetprotected Stringkeyprotected StringkeyLikeprotected booleanlatestprotected Stringnameprotected StringnameLikeprotected StringresourceNameprotected StringresourceNameLikeprotected String[]tenantIdsprotected Integerversion-
Fields inherited from class org.camunda.bpm.engine.impl.AbstractQuery
commandExecutor, expressions, maxResultsLimitEnabled, resultType, SORTORDER_ASC, SORTORDER_DESC, validators
-
Fields inherited from class org.camunda.bpm.engine.impl.db.ListQueryParameterObject
authCheck, databaseType, firstResult, maxResults, orderingProperties, parameter, tenantCheck
-
-
Constructor Summary
Constructors Constructor Description CaseDefinitionQueryImpl()CaseDefinitionQueryImpl(CommandExecutor commandExecutor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CaseDefinitionQuerycaseDefinitionCategory(String caseDefinitionCategory)Only select case definitions with the given category.CaseDefinitionQuerycaseDefinitionCategoryLike(String caseDefinitionCategoryLike)Only select case definitions where the category matches the given parameter.CaseDefinitionQuerycaseDefinitionId(String caseDefinitionId)Only select case definition with the given id.CaseDefinitionQuerycaseDefinitionIdIn(String... ids)Only select case definitions with the given ids.CaseDefinitionQuerycaseDefinitionKey(String caseDefinitionKey)Only select case definition with the given key.CaseDefinitionQuerycaseDefinitionKeyLike(String caseDefinitionKeyLike)Only select case definitions where the key matches the given parameter.CaseDefinitionQuerycaseDefinitionName(String caseDefinitionName)Only select case definitions with the given name.CaseDefinitionQuerycaseDefinitionNameLike(String caseDefinitionNameLike)Only select case definitions where the name matches the given parameter.CaseDefinitionQuerycaseDefinitionResourceName(String resourceName)Only select case definition with the given resource name.CaseDefinitionQuerycaseDefinitionResourceNameLike(String resourceNameLike)Only select case definition with a resource name like the given.CaseDefinitionQuerycaseDefinitionVersion(Integer caseDefinitionVersion)Only select case definition with a certain version.voidcheckQueryOk()CaseDefinitionQuerydeploymentId(String deploymentId)Only select case definitions that are deployed in a deployment with the given deployment id.longexecuteCount(CommandContext commandContext)List<CaseDefinition>executeList(CommandContext commandContext, Page page)Executes the actual query to retrieve the list of results.StringgetCategory()StringgetCategoryLike()StringgetDeploymentId()StringgetId()String[]getIds()StringgetKey()StringgetKeyLike()StringgetName()StringgetNameLike()StringgetResourceName()StringgetResourceNameLike()IntegergetVersion()protected booleanhasExcludingConditions()Whether or not the query has excluding conditions.CaseDefinitionQueryincludeCaseDefinitionsWithoutTenantId()Select case definitions which have no tenant id.booleanisLatest()CaseDefinitionQuerylatestVersion()Only select the case definitions which are the latest deployed (ie.CaseDefinitionQueryorderByCaseDefinitionCategory()Order by the category of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQueryorderByCaseDefinitionId()Order by the id of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQueryorderByCaseDefinitionKey()Order by case definition key (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQueryorderByCaseDefinitionName()Order by the name of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQueryorderByCaseDefinitionVersion()Order by the version of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQueryorderByDeploymentId()Order by deployment id (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQueryorderByTenantId()Order by tenant id (needs to be followed byQuery.asc()orQuery.desc()).CaseDefinitionQuerytenantIdIn(String... tenantIds)Only select case definitions with one of the given tenant ids.CaseDefinitionQuerywithoutTenantId()Only select case definitions which have no tenant id.-
Methods inherited from class org.camunda.bpm.engine.impl.AbstractQuery
addExpression, addValidator, asc, checkMaxResultsLimit, count, desc, direction, disableMaxResultsLimit, enableMaxResultsLimit, evaluateExpressions, evaluateExpressionsAndExecuteCount, evaluateExpressionsAndExecuteDeploymentIdMappingsList, evaluateExpressionsAndExecuteIdsList, evaluateExpressionsAndExecuteList, execute, executeDeploymentIdMappingsList, executeIdsList, executeResult, executeSingleResult, extend, getExpressions, getMethod, list, listDeploymentIdMappings, listIds, listPage, mergeExpressions, mergeOrdering, orderBy, orderBy, removeValidator, setCommandExecutor, setExpressions, singleResult, unlimitedList, validate, validate
-
Methods inherited from class org.camunda.bpm.engine.impl.db.ListQueryParameterObject
getAuthCheck, getDatabaseType, getFirstResult, getFirstRow, getLastRow, getMaxResults, getOrderingProperties, getParameter, getTenantCheck, setAuthCheck, setDatabaseType, setFirstResult, setMaxResults, setOrderingProperties, setParameter, setTenantCheck
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.camunda.bpm.engine.impl.interceptor.Command
isRetryable
-
Methods inherited from interface org.camunda.bpm.engine.query.Query
asc, count, desc, list, listPage, singleResult, unlimitedList
-
-
-
-
Field Detail
-
id
protected String id
-
ids
protected String[] ids
-
category
protected String category
-
categoryLike
protected String categoryLike
-
name
protected String name
-
nameLike
protected String nameLike
-
deploymentId
protected String deploymentId
-
key
protected String key
-
keyLike
protected String keyLike
-
resourceName
protected String resourceName
-
resourceNameLike
protected String resourceNameLike
-
version
protected Integer version
-
latest
protected boolean latest
-
isTenantIdSet
protected boolean isTenantIdSet
-
tenantIds
protected String[] tenantIds
-
includeDefinitionsWithoutTenantId
protected boolean includeDefinitionsWithoutTenantId
-
-
Constructor Detail
-
CaseDefinitionQueryImpl
public CaseDefinitionQueryImpl()
-
CaseDefinitionQueryImpl
public CaseDefinitionQueryImpl(CommandExecutor commandExecutor)
-
-
Method Detail
-
caseDefinitionId
public CaseDefinitionQuery caseDefinitionId(String caseDefinitionId)
Description copied from interface:CaseDefinitionQueryOnly select case definition with the given id.- Specified by:
caseDefinitionIdin interfaceCaseDefinitionQuery- Parameters:
caseDefinitionId- the id of the case definition
-
caseDefinitionIdIn
public CaseDefinitionQuery caseDefinitionIdIn(String... ids)
Description copied from interface:CaseDefinitionQueryOnly select case definitions with the given ids.- Specified by:
caseDefinitionIdInin interfaceCaseDefinitionQuery- Parameters:
ids- list of case definition ids
-
caseDefinitionCategory
public CaseDefinitionQuery caseDefinitionCategory(String caseDefinitionCategory)
Description copied from interface:CaseDefinitionQueryOnly select case definitions with the given category.- Specified by:
caseDefinitionCategoryin interfaceCaseDefinitionQuery- Parameters:
caseDefinitionCategory- the category of the case definition
-
caseDefinitionCategoryLike
public CaseDefinitionQuery caseDefinitionCategoryLike(String caseDefinitionCategoryLike)
Description copied from interface:CaseDefinitionQueryOnly select case definitions where the category matches the given parameter. The syntax that should be used is the same as in SQL, eg. %activiti%- Specified by:
caseDefinitionCategoryLikein interfaceCaseDefinitionQuery- Parameters:
caseDefinitionCategoryLike- the pattern to match the case definition category
-
caseDefinitionName
public CaseDefinitionQuery caseDefinitionName(String caseDefinitionName)
Description copied from interface:CaseDefinitionQueryOnly select case definitions with the given name.- Specified by:
caseDefinitionNamein interfaceCaseDefinitionQuery- Parameters:
caseDefinitionName- the name of the case definition
-
caseDefinitionNameLike
public CaseDefinitionQuery caseDefinitionNameLike(String caseDefinitionNameLike)
Description copied from interface:CaseDefinitionQueryOnly select case definitions where the name matches the given parameter. The syntax that should be used is the same as in SQL, eg. %activiti%- Specified by:
caseDefinitionNameLikein interfaceCaseDefinitionQuery- Parameters:
caseDefinitionNameLike- the pattern to match the case definition name
-
caseDefinitionKey
public CaseDefinitionQuery caseDefinitionKey(String caseDefinitionKey)
Description copied from interface:CaseDefinitionQueryOnly select case definition with the given key.- Specified by:
caseDefinitionKeyin interfaceCaseDefinitionQuery- Parameters:
caseDefinitionKey- the key of the case definition
-
caseDefinitionKeyLike
public CaseDefinitionQuery caseDefinitionKeyLike(String caseDefinitionKeyLike)
Description copied from interface:CaseDefinitionQueryOnly select case definitions where the key matches the given parameter. The syntax that should be used is the same as in SQL, eg. %activiti%- Specified by:
caseDefinitionKeyLikein interfaceCaseDefinitionQuery- Parameters:
caseDefinitionKeyLike- the pattern to match the case definition key
-
deploymentId
public CaseDefinitionQuery deploymentId(String deploymentId)
Description copied from interface:CaseDefinitionQueryOnly select case definitions that are deployed in a deployment with the given deployment id.- Specified by:
deploymentIdin interfaceCaseDefinitionQuery- Parameters:
deploymentId- the id of the deployment
-
caseDefinitionVersion
public CaseDefinitionQuery caseDefinitionVersion(Integer caseDefinitionVersion)
Description copied from interface:CaseDefinitionQueryOnly select case definition with a certain version. Particularly useful when used in combination withCaseDefinitionQuery.caseDefinitionKey(String)- Specified by:
caseDefinitionVersionin interfaceCaseDefinitionQuery- Parameters:
caseDefinitionVersion- the version of the case definition
-
latestVersion
public CaseDefinitionQuery latestVersion()
Description copied from interface:CaseDefinitionQueryOnly select the case definitions which are the latest deployed (ie. which have the highest version number for the given key). Can only be used in combination withCaseDefinitionQuery.caseDefinitionKey(String)orCaseDefinitionQuery.caseDefinitionKeyLike(String). Can also be used without any other criteria (ie. query.latest().list()), which will then give all the latest versions of all the deployed case definitions.- Specified by:
latestVersionin interfaceCaseDefinitionQuery
-
caseDefinitionResourceName
public CaseDefinitionQuery caseDefinitionResourceName(String resourceName)
Description copied from interface:CaseDefinitionQueryOnly select case definition with the given resource name.- Specified by:
caseDefinitionResourceNamein interfaceCaseDefinitionQuery- Parameters:
resourceName- the name of the resource
-
caseDefinitionResourceNameLike
public CaseDefinitionQuery caseDefinitionResourceNameLike(String resourceNameLike)
Description copied from interface:CaseDefinitionQueryOnly select case definition with a resource name like the given. The syntax that should be used is the same as in SQL, eg. %activiti%- Specified by:
caseDefinitionResourceNameLikein interfaceCaseDefinitionQuery- Parameters:
resourceNameLike- the pattern to match the resource name
-
tenantIdIn
public CaseDefinitionQuery tenantIdIn(String... tenantIds)
Description copied from interface:CaseDefinitionQueryOnly select case definitions with one of the given tenant ids.- Specified by:
tenantIdInin interfaceCaseDefinitionQuery
-
withoutTenantId
public CaseDefinitionQuery withoutTenantId()
Description copied from interface:CaseDefinitionQueryOnly select case definitions which have no tenant id.- Specified by:
withoutTenantIdin interfaceCaseDefinitionQuery
-
includeCaseDefinitionsWithoutTenantId
public CaseDefinitionQuery includeCaseDefinitionsWithoutTenantId()
Description copied from interface:CaseDefinitionQuerySelect case definitions which have no tenant id. Can be used in combination withCaseDefinitionQuery.tenantIdIn(String...).- Specified by:
includeCaseDefinitionsWithoutTenantIdin interfaceCaseDefinitionQuery
-
orderByCaseDefinitionCategory
public CaseDefinitionQuery orderByCaseDefinitionCategory()
Description copied from interface:CaseDefinitionQueryOrder by the category of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).- Specified by:
orderByCaseDefinitionCategoryin interfaceCaseDefinitionQuery
-
orderByCaseDefinitionKey
public CaseDefinitionQuery orderByCaseDefinitionKey()
Description copied from interface:CaseDefinitionQueryOrder by case definition key (needs to be followed byQuery.asc()orQuery.desc()).- Specified by:
orderByCaseDefinitionKeyin interfaceCaseDefinitionQuery
-
orderByCaseDefinitionId
public CaseDefinitionQuery orderByCaseDefinitionId()
Description copied from interface:CaseDefinitionQueryOrder by the id of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).- Specified by:
orderByCaseDefinitionIdin interfaceCaseDefinitionQuery
-
orderByCaseDefinitionVersion
public CaseDefinitionQuery orderByCaseDefinitionVersion()
Description copied from interface:CaseDefinitionQueryOrder by the version of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).- Specified by:
orderByCaseDefinitionVersionin interfaceCaseDefinitionQuery
-
orderByCaseDefinitionName
public CaseDefinitionQuery orderByCaseDefinitionName()
Description copied from interface:CaseDefinitionQueryOrder by the name of the case definitions (needs to be followed byQuery.asc()orQuery.desc()).- Specified by:
orderByCaseDefinitionNamein interfaceCaseDefinitionQuery
-
orderByDeploymentId
public CaseDefinitionQuery orderByDeploymentId()
Description copied from interface:CaseDefinitionQueryOrder by deployment id (needs to be followed byQuery.asc()orQuery.desc()).- Specified by:
orderByDeploymentIdin interfaceCaseDefinitionQuery
-
orderByTenantId
public CaseDefinitionQuery orderByTenantId()
Description copied from interface:CaseDefinitionQueryOrder by tenant id (needs to be followed byQuery.asc()orQuery.desc()). Note that the ordering of case instances without tenant id is database-specific.- Specified by:
orderByTenantIdin interfaceCaseDefinitionQuery
-
hasExcludingConditions
protected boolean hasExcludingConditions()
Description copied from class:AbstractQueryWhether or not the query has excluding conditions. If the query has excluding conditions, (e.g. task due date before and after are excluding), the SQL query is avoided and a default result is returned. The returned result is the same as if the SQL was executed and there were no entries.- Overrides:
hasExcludingConditionsin classAbstractQuery<CaseDefinitionQuery,CaseDefinition>- Returns:
trueif the query does have excluding conditions,falseotherwise
-
executeCount
public long executeCount(CommandContext commandContext)
- Specified by:
executeCountin classAbstractQuery<CaseDefinitionQuery,CaseDefinition>
-
executeList
public List<CaseDefinition> executeList(CommandContext commandContext, Page page)
Description copied from class:AbstractQueryExecutes the actual query to retrieve the list of results.- Specified by:
executeListin classAbstractQuery<CaseDefinitionQuery,CaseDefinition>page- used if the results must be paged. If null, no paging will be applied.
-
checkQueryOk
public void checkQueryOk()
- Overrides:
checkQueryOkin classAbstractQuery<CaseDefinitionQuery,CaseDefinition>
-
getId
public String getId()
-
getIds
public String[] getIds()
-
getCategory
public String getCategory()
-
getCategoryLike
public String getCategoryLike()
-
getName
public String getName()
-
getNameLike
public String getNameLike()
-
getDeploymentId
public String getDeploymentId()
-
getKey
public String getKey()
-
getKeyLike
public String getKeyLike()
-
getResourceName
public String getResourceName()
-
getResourceNameLike
public String getResourceNameLike()
-
getVersion
public Integer getVersion()
-
isLatest
public boolean isLatest()
-
-