Package org.camunda.bpm.engine.impl
Class HistoricProcessInstanceQueryImpl
- java.lang.Object
-
- org.camunda.bpm.engine.impl.db.ListQueryParameterObject
-
- org.camunda.bpm.engine.impl.AbstractQuery<T,U>
-
- org.camunda.bpm.engine.impl.AbstractVariableQueryImpl<HistoricProcessInstanceQuery,HistoricProcessInstance>
-
- org.camunda.bpm.engine.impl.HistoricProcessInstanceQueryImpl
-
- All Implemented Interfaces:
java.io.Serializable
,HistoricProcessInstanceQuery
,Command<java.lang.Object>
,Query<HistoricProcessInstanceQuery,HistoricProcessInstance>
public class HistoricProcessInstanceQueryImpl extends AbstractVariableQueryImpl<HistoricProcessInstanceQuery,HistoricProcessInstance> implements HistoricProcessInstanceQuery
- Author:
- Tom Baeyens, Falko Menge, Bernd Ruecker
- 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 java.lang.String[]
activeActivityIds
protected java.lang.String
businessKey
protected java.lang.String[]
businessKeyIn
protected java.lang.String
businessKeyLike
protected java.lang.String
caseInstanceId
protected java.util.Date
executedActivityAfter
protected java.util.Date
executedActivityBefore
protected java.lang.String[]
executedActivityIds
protected java.util.Date
executedJobAfter
protected java.util.Date
executedJobBefore
protected java.util.Date
finishDateBy
protected java.util.Date
finishDateOn
protected java.util.Date
finishDateOnBegin
protected java.util.Date
finishDateOnEnd
protected boolean
finished
protected java.util.Date
finishedAfter
protected java.util.Date
finishedBefore
protected java.lang.String
incidentMessage
protected java.lang.String
incidentMessageLike
protected java.lang.String
incidentStatus
protected java.lang.String
incidentType
protected boolean
isOrQueryActive
protected boolean
isRootProcessInstances
protected boolean
isTenantIdSet
protected java.lang.String
processDefinitionId
protected java.lang.String
processDefinitionKey
protected java.lang.String[]
processDefinitionKeys
protected java.lang.String
processDefinitionName
protected java.lang.String
processDefinitionNameLike
protected java.lang.String
processInstanceId
protected java.util.Set<java.lang.String>
processInstanceIds
protected java.util.List<java.lang.String>
processKeyNotIn
protected java.util.List<HistoricProcessInstanceQueryImpl>
queries
protected java.util.Map<java.lang.String,java.util.Set<QueryVariableValue>>
queryVariableNameToValuesMap
protected java.util.Date
startDateBy
protected java.util.Date
startDateOn
protected java.util.Date
startDateOnBegin
protected java.util.Date
startDateOnEnd
protected java.util.Date
startedAfter
protected java.util.Date
startedBefore
protected java.lang.String
startedBy
protected java.lang.String
state
protected java.lang.String
subCaseInstanceId
protected java.lang.String
subProcessInstanceId
protected java.lang.String
superCaseInstanceId
protected java.lang.String
superProcessInstanceId
protected java.lang.String[]
tenantIds
protected boolean
unfinished
protected boolean
withIncidents
protected boolean
withRootIncidents
-
Fields inherited from class org.camunda.bpm.engine.impl.AbstractVariableQueryImpl
queryVariableValues, variableNamesIgnoreCase, variableValuesIgnoreCase
-
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 HistoricProcessInstanceQueryImpl()
HistoricProcessInstanceQueryImpl(CommandExecutor commandExecutor)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description HistoricProcessInstanceQuery
active()
Only select historic process instances that are active.HistoricProcessInstanceQuery
activeActivityIdIn(java.lang.String... ids)
Only select historic process instances that have active activities with given ids.void
addOrQuery(HistoricProcessInstanceQueryImpl orQuery)
protected void
addVariable(java.lang.String name, java.lang.Object value, QueryOperator operator, boolean processInstanceScope)
HistoricProcessInstanceQuery
caseInstanceId(java.lang.String caseInstanceId)
Only select historic process instances which are associated with the given case instance id.HistoricProcessInstanceQuery
completed()
Only select historic process instances that are completed.HistoricProcessInstanceQuery
endOr()
endOr() terminates an OR query on which an arbitrary amount of filter criteria were applied.protected void
ensureVariablesInitialized()
long
executeCount(CommandContext commandContext)
HistoricProcessInstanceQuery
executedActivityAfter(java.util.Date date)
Only select historic process instances that executed an activity after the given date.HistoricProcessInstanceQuery
executedActivityBefore(java.util.Date date)
Only select historic process instances that executed an activity before the given date.HistoricProcessInstanceQuery
executedActivityIdIn(java.lang.String... ids)
Only select historic process instances that executed activities with given ids.java.util.List<ImmutablePair<java.lang.String,java.lang.String>>
executeDeploymentIdMappingsList(CommandContext commandContext)
HistoricProcessInstanceQuery
executedJobAfter(java.util.Date date)
Only select historic process instances that executed an job after the given date.HistoricProcessInstanceQuery
executedJobBefore(java.util.Date date)
Only select historic process instances that executed an job before the given date.java.util.List<java.lang.String>
executeIdsList(CommandContext commandContext)
java.util.List<HistoricProcessInstance>
executeList(CommandContext commandContext, Page page)
Executes the actual query to retrieve the list of results.HistoricProcessInstanceQuery
externallyTerminated()
Only select historic process instances that are externallyTerminated.HistoricProcessInstanceQuery
finishDateBy(java.util.Date date)
Deprecated.HistoricProcessInstanceQuery
finishDateOn(java.util.Date date)
Deprecated.HistoricProcessInstanceQuery
finished()
Only select historic process instances that are completely finished.HistoricProcessInstanceQuery
finishedAfter(java.util.Date date)
Only select historic process instances that were started after the given date.HistoricProcessInstanceQuery
finishedBefore(java.util.Date date)
Only select historic process instances that were started before the given date.java.lang.String[]
getActiveActivityIds()
java.lang.String
getBusinessKey()
java.lang.String[]
getBusinessKeyIn()
java.lang.String
getBusinessKeyLike()
java.lang.String
getCaseInstanceId()
java.util.Date
getExecutedActivityAfter()
java.util.Date
getExecutedActivityBefore()
java.lang.String[]
getExecutedActivityIds()
java.util.Date
getExecutedJobAfter()
java.util.Date
getExecutedJobBefore()
java.util.Date
getFinishDateBy()
java.util.Date
getFinishDateOn()
java.util.Date
getFinishDateOnBegin()
java.util.Date
getFinishDateOnEnd()
java.util.Date
getFinishedAfter()
java.util.Date
getFinishedBefore()
java.lang.String
getIncidentMessage()
java.lang.String
getIncidentMessageLike()
java.lang.String
getIncidentStatus()
java.lang.String
getIncidentType()
boolean
getIsTenantIdSet()
java.lang.String
getProcessDefinitionId()
java.lang.String
getProcessDefinitionIdLike()
java.lang.String
getProcessDefinitionKey()
java.lang.String[]
getProcessDefinitionKeys()
java.lang.String
getProcessDefinitionName()
java.lang.String
getProcessDefinitionNameLike()
java.lang.String
getProcessInstanceId()
java.util.Set<java.lang.String>
getProcessInstanceIds()
java.util.List<java.lang.String>
getProcessKeyNotIn()
java.util.List<HistoricProcessInstanceQueryImpl>
getQueries()
java.util.Map<java.lang.String,java.util.Set<QueryVariableValue>>
getQueryVariableNameToValuesMap()
java.util.List<QueryVariableValue>
getQueryVariableValues()
java.util.Date
getStartDateBy()
java.util.Date
getStartDateOn()
java.util.Date
getStartDateOnBegin()
java.util.Date
getStartDateOnEnd()
java.util.Date
getStartedAfter()
java.util.Date
getStartedBefore()
java.lang.String
getStartedBy()
java.lang.String
getState()
java.lang.String
getSubCaseInstanceId()
java.lang.String
getSubProcessInstanceId()
java.lang.String
getSuperCaseInstanceId()
java.lang.String
getSuperProcessInstanceId()
java.lang.String[]
getTenantIds()
protected boolean
hasExcludingConditions()
Whether or not the query has excluding conditions.HistoricProcessInstanceQuery
incidentMessage(java.lang.String incidentMessage)
Only select historic process instances with the given incident message.HistoricProcessInstanceQuery
incidentMessageLike(java.lang.String incidentMessageLike)
Only select historic process instances which had an incident message like the given value.HistoricProcessInstanceQuery
incidentStatus(java.lang.String status)
Only select historic process instances with incident status either 'open' or 'resolved'.HistoricProcessInstanceQuery
incidentType(java.lang.String incidentType)
Only selects process instances with the given incident type.HistoricProcessInstanceQuery
internallyTerminated()
Only select historic process instances that are internallyTerminated.boolean
isFinished()
boolean
isOpen()
boolean
isOrQueryActive()
boolean
isRootProcessInstances()
boolean
isTenantIdSet()
boolean
isUnfinished()
boolean
isWithIncidents()
boolean
isWithRootIncidents()
HistoricProcessInstanceQuery
or()
After calling or(), a chain of several filter criteria could follow.HistoricProcessInstanceQuery
orderByProcessDefinitionId()
Order by the process definition id (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessDefinitionKey()
Order by the process definition key (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessDefinitionName()
Order by the process definition name (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessDefinitionVersion()
Order by the process definition version (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessInstanceBusinessKey()
Order by the business key (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessInstanceDuration()
Order by the duration of the process instance (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessInstanceEndTime()
Order by the end time (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessInstanceId()
Order by the process instance id (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByProcessInstanceStartTime()
Order by the start time (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQuery
orderByTenantId()
Order by tenant id (needs to be followed byQuery.asc()
orQuery.desc()
).HistoricProcessInstanceQueryImpl
processDefinitionId(java.lang.String processDefinitionId)
Only select historic process instances for the given process definitionHistoricProcessInstanceQuery
processDefinitionKey(java.lang.String processDefinitionKey)
Only select historic process instances that are defined by a process definition with the given key.HistoricProcessInstanceQuery
processDefinitionKeyIn(java.lang.String... processDefinitionKeys)
Only select historic process instances that are defined by any given process definition key.HistoricProcessInstanceQuery
processDefinitionKeyNotIn(java.util.List<java.lang.String> processDefinitionKeys)
Only select historic process instances that don't have a process-definition of which the key is present in the given listHistoricProcessInstanceQuery
processDefinitionName(java.lang.String processDefinitionName)
Only select historic process instances that are defined by a process definition with the given name.HistoricProcessInstanceQuery
processDefinitionNameLike(java.lang.String nameLike)
Only select historic process instances that are defined by process definition which name is like the given value.HistoricProcessInstanceQuery
processInstanceBusinessKey(java.lang.String businessKey)
Only select historic process instances with the given business keyHistoricProcessInstanceQuery
processInstanceBusinessKeyIn(java.lang.String... businessKeyIn)
Only select historic process instances whose business key is in the given set.HistoricProcessInstanceQuery
processInstanceBusinessKeyLike(java.lang.String businessKeyLike)
Only select historic process instances which had a business key like the given value.HistoricProcessInstanceQueryImpl
processInstanceId(java.lang.String processInstanceId)
Only select historic process instances with the given process instance.HistoricProcessInstanceQuery
processInstanceIds(java.util.Set<java.lang.String> processInstanceIds)
Only select historic process instances whose id is in the given set of ids.HistoricProcessInstanceQuery
rootProcessInstances()
Only select historic process instances that are top level process instances.void
setOrQueryActive()
void
setSuperProcessInstanceId(java.lang.String superProcessInstanceId)
HistoricProcessInstanceQuery
startDateBy(java.util.Date date)
Deprecated.HistoricProcessInstanceQuery
startDateOn(java.util.Date date)
Deprecated.HistoricProcessInstanceQuery
startedAfter(java.util.Date date)
Only select historic process instances that were started after the given date.HistoricProcessInstanceQuery
startedBefore(java.util.Date date)
Only select historic process instances that were started before the given date.HistoricProcessInstanceQuery
startedBy(java.lang.String userId)
Only select historic process instance that are started by the given user.HistoricProcessInstanceQuery
subCaseInstanceId(java.lang.String subCaseInstanceId)
Only select historic process instances having a sub case instance with the given case instance id.HistoricProcessInstanceQuery
subProcessInstanceId(java.lang.String subProcessInstanceId)
Only select historic process instances having a sub process instance with the given process instance id.HistoricProcessInstanceQuery
superCaseInstanceId(java.lang.String superCaseInstanceId)
Only select historic process instances started by the given case instance.HistoricProcessInstanceQuery
superProcessInstanceId(java.lang.String superProcessInstanceId)
Only select historic process instances started by the given process instance.HistoricProcessInstanceQuery
suspended()
Only select historic process instances that are suspended.HistoricProcessInstanceQuery
tenantIdIn(java.lang.String... tenantIds)
Only select historic process instances with one of the given tenant ids.HistoricProcessInstanceQuery
unfinished()
Only select historic process instance that are not yet finished.HistoricProcessInstanceQuery
withIncidents()
Only select historic process instances with incidentsHistoricProcessInstanceQuery
withoutTenantId()
Only selects historic process instances which have no tenant id.HistoricProcessInstanceQuery
withRootIncidents()
Only select historic process instances with root incidents-
Methods inherited from class org.camunda.bpm.engine.impl.AbstractVariableQueryImpl
createQueryVariableValue, isVariableNamesIgnoreCase, isVariableValuesIgnoreCase, matchVariableNamesIgnoreCase, matchVariableValuesIgnoreCase, validateVariable, variableValueEquals, variableValueGreaterThan, variableValueGreaterThanOrEqual, variableValueLessThan, variableValueLessThanOrEqual, variableValueLike, variableValueNotEquals, variableValueNotLike
-
Methods inherited from class org.camunda.bpm.engine.impl.AbstractQuery
addExpression, addValidator, asc, checkMaxResultsLimit, checkQueryOk, count, desc, direction, disableMaxResultsLimit, enableMaxResultsLimit, evaluateExpressions, evaluateExpressionsAndExecuteCount, evaluateExpressionsAndExecuteDeploymentIdMappingsList, evaluateExpressionsAndExecuteIdsList, evaluateExpressionsAndExecuteList, execute, 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.history.HistoricProcessInstanceQuery
matchVariableNamesIgnoreCase, matchVariableValuesIgnoreCase, variableValueEquals, variableValueGreaterThan, variableValueGreaterThanOrEqual, variableValueLessThan, variableValueLessThanOrEqual, variableValueLike, variableValueNotEquals
-
Methods inherited from interface org.camunda.bpm.engine.query.Query
asc, count, desc, list, listPage, singleResult, unlimitedList
-
-
-
-
Field Detail
-
processInstanceId
protected java.lang.String processInstanceId
-
processDefinitionId
protected java.lang.String processDefinitionId
-
processDefinitionName
protected java.lang.String processDefinitionName
-
processDefinitionNameLike
protected java.lang.String processDefinitionNameLike
-
businessKey
protected java.lang.String businessKey
-
businessKeyIn
protected java.lang.String[] businessKeyIn
-
businessKeyLike
protected java.lang.String businessKeyLike
-
finished
protected boolean finished
-
unfinished
protected boolean unfinished
-
withIncidents
protected boolean withIncidents
-
withRootIncidents
protected boolean withRootIncidents
-
incidentType
protected java.lang.String incidentType
-
incidentStatus
protected java.lang.String incidentStatus
-
incidentMessage
protected java.lang.String incidentMessage
-
incidentMessageLike
protected java.lang.String incidentMessageLike
-
startedBy
protected java.lang.String startedBy
-
isRootProcessInstances
protected boolean isRootProcessInstances
-
superProcessInstanceId
protected java.lang.String superProcessInstanceId
-
subProcessInstanceId
protected java.lang.String subProcessInstanceId
-
superCaseInstanceId
protected java.lang.String superCaseInstanceId
-
subCaseInstanceId
protected java.lang.String subCaseInstanceId
-
processKeyNotIn
protected java.util.List<java.lang.String> processKeyNotIn
-
startedBefore
protected java.util.Date startedBefore
-
startedAfter
protected java.util.Date startedAfter
-
finishedBefore
protected java.util.Date finishedBefore
-
finishedAfter
protected java.util.Date finishedAfter
-
executedActivityAfter
protected java.util.Date executedActivityAfter
-
executedActivityBefore
protected java.util.Date executedActivityBefore
-
executedJobAfter
protected java.util.Date executedJobAfter
-
executedJobBefore
protected java.util.Date executedJobBefore
-
processDefinitionKey
protected java.lang.String processDefinitionKey
-
processDefinitionKeys
protected java.lang.String[] processDefinitionKeys
-
processInstanceIds
protected java.util.Set<java.lang.String> processInstanceIds
-
tenantIds
protected java.lang.String[] tenantIds
-
isTenantIdSet
protected boolean isTenantIdSet
-
executedActivityIds
protected java.lang.String[] executedActivityIds
-
activeActivityIds
protected java.lang.String[] activeActivityIds
-
state
protected java.lang.String state
-
caseInstanceId
protected java.lang.String caseInstanceId
-
queries
protected java.util.List<HistoricProcessInstanceQueryImpl> queries
-
isOrQueryActive
protected boolean isOrQueryActive
-
queryVariableNameToValuesMap
protected java.util.Map<java.lang.String,java.util.Set<QueryVariableValue>> queryVariableNameToValuesMap
-
startDateBy
protected java.util.Date startDateBy
-
startDateOn
protected java.util.Date startDateOn
-
finishDateBy
protected java.util.Date finishDateBy
-
finishDateOn
protected java.util.Date finishDateOn
-
startDateOnBegin
protected java.util.Date startDateOnBegin
-
startDateOnEnd
protected java.util.Date startDateOnEnd
-
finishDateOnBegin
protected java.util.Date finishDateOnBegin
-
finishDateOnEnd
protected java.util.Date finishDateOnEnd
-
-
Constructor Detail
-
HistoricProcessInstanceQueryImpl
public HistoricProcessInstanceQueryImpl()
-
HistoricProcessInstanceQueryImpl
public HistoricProcessInstanceQueryImpl(CommandExecutor commandExecutor)
-
-
Method Detail
-
processInstanceId
public HistoricProcessInstanceQueryImpl processInstanceId(java.lang.String processInstanceId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with the given process instance. {@link ProcessInstance) ids and {@link HistoricProcessInstance} ids match.- Specified by:
processInstanceId
in interfaceHistoricProcessInstanceQuery
-
processInstanceIds
public HistoricProcessInstanceQuery processInstanceIds(java.util.Set<java.lang.String> processInstanceIds)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances whose id is in the given set of ids. {@link ProcessInstance) ids and {@link HistoricProcessInstance} ids match.- Specified by:
processInstanceIds
in interfaceHistoricProcessInstanceQuery
-
processDefinitionId
public HistoricProcessInstanceQueryImpl processDefinitionId(java.lang.String processDefinitionId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances for the given process definition- Specified by:
processDefinitionId
in interfaceHistoricProcessInstanceQuery
-
processDefinitionKey
public HistoricProcessInstanceQuery processDefinitionKey(java.lang.String processDefinitionKey)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are defined by a process definition with the given key.- Specified by:
processDefinitionKey
in interfaceHistoricProcessInstanceQuery
-
processDefinitionKeyIn
public HistoricProcessInstanceQuery processDefinitionKeyIn(java.lang.String... processDefinitionKeys)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are defined by any given process definition key.- Specified by:
processDefinitionKeyIn
in interfaceHistoricProcessInstanceQuery
-
processDefinitionName
public HistoricProcessInstanceQuery processDefinitionName(java.lang.String processDefinitionName)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are defined by a process definition with the given name.- Specified by:
processDefinitionName
in interfaceHistoricProcessInstanceQuery
-
processDefinitionNameLike
public HistoricProcessInstanceQuery processDefinitionNameLike(java.lang.String nameLike)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are defined by process definition which name is like the given value.- Specified by:
processDefinitionNameLike
in interfaceHistoricProcessInstanceQuery
- Parameters:
nameLike
- The string can include the wildcard character '%' to express like-strategy: starts with (string%), ends with (%string) or contains (%string%).
-
processInstanceBusinessKey
public HistoricProcessInstanceQuery processInstanceBusinessKey(java.lang.String businessKey)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with the given business key- Specified by:
processInstanceBusinessKey
in interfaceHistoricProcessInstanceQuery
-
processInstanceBusinessKeyIn
public HistoricProcessInstanceQuery processInstanceBusinessKeyIn(java.lang.String... businessKeyIn)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances whose business key is in the given set.- Specified by:
processInstanceBusinessKeyIn
in interfaceHistoricProcessInstanceQuery
-
processInstanceBusinessKeyLike
public HistoricProcessInstanceQuery processInstanceBusinessKeyLike(java.lang.String businessKeyLike)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances which had a business key like the given value.- Specified by:
processInstanceBusinessKeyLike
in interfaceHistoricProcessInstanceQuery
- Parameters:
businessKeyLike
- The string can include the wildcard character '%' to express like-strategy: starts with (string%), ends with (%string) or contains (%string%).
-
finished
public HistoricProcessInstanceQuery finished()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are completely finished.- Specified by:
finished
in interfaceHistoricProcessInstanceQuery
-
unfinished
public HistoricProcessInstanceQuery unfinished()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instance that are not yet finished.- Specified by:
unfinished
in interfaceHistoricProcessInstanceQuery
-
withIncidents
public HistoricProcessInstanceQuery withIncidents()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with incidents- Specified by:
withIncidents
in interfaceHistoricProcessInstanceQuery
- Returns:
- HistoricProcessInstanceQuery
-
withRootIncidents
public HistoricProcessInstanceQuery withRootIncidents()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with root incidents- Specified by:
withRootIncidents
in interfaceHistoricProcessInstanceQuery
- Returns:
- HistoricProcessInstanceQuery
-
incidentType
public HistoricProcessInstanceQuery incidentType(java.lang.String incidentType)
Description copied from interface:HistoricProcessInstanceQuery
Only selects process instances with the given incident type.- Specified by:
incidentType
in interfaceHistoricProcessInstanceQuery
-
incidentStatus
public HistoricProcessInstanceQuery incidentStatus(java.lang.String status)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with incident status either 'open' or 'resolved'. To get all process instances with incidents, useHistoricProcessInstanceQuery.withIncidents()
.- Specified by:
incidentStatus
in interfaceHistoricProcessInstanceQuery
- Parameters:
status
- indicates the incident status, which is either 'open' or 'resolved'- Returns:
HistoricProcessInstanceQuery
-
incidentMessage
public HistoricProcessInstanceQuery incidentMessage(java.lang.String incidentMessage)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with the given incident message.- Specified by:
incidentMessage
in interfaceHistoricProcessInstanceQuery
- Parameters:
incidentMessage
- Incidents Message for which the historic process instances should be selected- Returns:
- HistoricProcessInstanceQuery
-
incidentMessageLike
public HistoricProcessInstanceQuery incidentMessageLike(java.lang.String incidentMessageLike)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances which had an incident message like the given value.- Specified by:
incidentMessageLike
in interfaceHistoricProcessInstanceQuery
- Parameters:
incidentMessageLike
- The string can include the wildcard character '%' to express like-strategy: starts with (string%), ends with (%string) or contains (%string%).- Returns:
- HistoricProcessInstanceQuery
-
startedBy
public HistoricProcessInstanceQuery startedBy(java.lang.String userId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instance that are started by the given user.- Specified by:
startedBy
in interfaceHistoricProcessInstanceQuery
-
processDefinitionKeyNotIn
public HistoricProcessInstanceQuery processDefinitionKeyNotIn(java.util.List<java.lang.String> processDefinitionKeys)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that don't have a process-definition of which the key is present in the given list- Specified by:
processDefinitionKeyNotIn
in interfaceHistoricProcessInstanceQuery
-
startedAfter
public HistoricProcessInstanceQuery startedAfter(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were started after the given date.- Specified by:
startedAfter
in interfaceHistoricProcessInstanceQuery
-
startedBefore
public HistoricProcessInstanceQuery startedBefore(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were started before the given date.- Specified by:
startedBefore
in interfaceHistoricProcessInstanceQuery
-
finishedAfter
public HistoricProcessInstanceQuery finishedAfter(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were started after the given date.- Specified by:
finishedAfter
in interfaceHistoricProcessInstanceQuery
-
finishedBefore
public HistoricProcessInstanceQuery finishedBefore(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were started before the given date.- Specified by:
finishedBefore
in interfaceHistoricProcessInstanceQuery
-
rootProcessInstances
public HistoricProcessInstanceQuery rootProcessInstances()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are top level process instances.- Specified by:
rootProcessInstances
in interfaceHistoricProcessInstanceQuery
-
superProcessInstanceId
public HistoricProcessInstanceQuery superProcessInstanceId(java.lang.String superProcessInstanceId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances started by the given process instance. {@link ProcessInstance) ids and {@link HistoricProcessInstance} ids match.- Specified by:
superProcessInstanceId
in interfaceHistoricProcessInstanceQuery
-
subProcessInstanceId
public HistoricProcessInstanceQuery subProcessInstanceId(java.lang.String subProcessInstanceId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances having a sub process instance with the given process instance id. Note that there will always be maximum only one such process instance that can be the result of this query.- Specified by:
subProcessInstanceId
in interfaceHistoricProcessInstanceQuery
-
superCaseInstanceId
public HistoricProcessInstanceQuery superCaseInstanceId(java.lang.String superCaseInstanceId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances started by the given case instance.- Specified by:
superCaseInstanceId
in interfaceHistoricProcessInstanceQuery
-
subCaseInstanceId
public HistoricProcessInstanceQuery subCaseInstanceId(java.lang.String subCaseInstanceId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances having a sub case instance with the given case instance id. Note that there will always be maximum only one such process instance that can be the result of this query.- Specified by:
subCaseInstanceId
in interfaceHistoricProcessInstanceQuery
-
caseInstanceId
public HistoricProcessInstanceQuery caseInstanceId(java.lang.String caseInstanceId)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances which are associated with the given case instance id.- Specified by:
caseInstanceId
in interfaceHistoricProcessInstanceQuery
-
tenantIdIn
public HistoricProcessInstanceQuery tenantIdIn(java.lang.String... tenantIds)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances with one of the given tenant ids.- Specified by:
tenantIdIn
in interfaceHistoricProcessInstanceQuery
-
withoutTenantId
public HistoricProcessInstanceQuery withoutTenantId()
Description copied from interface:HistoricProcessInstanceQuery
Only selects historic process instances which have no tenant id.- Specified by:
withoutTenantId
in interfaceHistoricProcessInstanceQuery
-
hasExcludingConditions
protected boolean hasExcludingConditions()
Description copied from class:AbstractQuery
Whether 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:
hasExcludingConditions
in classAbstractQuery<HistoricProcessInstanceQuery,HistoricProcessInstance>
- Returns:
true
if the query does have excluding conditions,false
otherwise
-
orderByProcessInstanceBusinessKey
public HistoricProcessInstanceQuery orderByProcessInstanceBusinessKey()
Description copied from interface:HistoricProcessInstanceQuery
Order by the business key (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessInstanceBusinessKey
in interfaceHistoricProcessInstanceQuery
-
orderByProcessInstanceDuration
public HistoricProcessInstanceQuery orderByProcessInstanceDuration()
Description copied from interface:HistoricProcessInstanceQuery
Order by the duration of the process instance (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessInstanceDuration
in interfaceHistoricProcessInstanceQuery
-
orderByProcessInstanceStartTime
public HistoricProcessInstanceQuery orderByProcessInstanceStartTime()
Description copied from interface:HistoricProcessInstanceQuery
Order by the start time (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessInstanceStartTime
in interfaceHistoricProcessInstanceQuery
-
orderByProcessInstanceEndTime
public HistoricProcessInstanceQuery orderByProcessInstanceEndTime()
Description copied from interface:HistoricProcessInstanceQuery
Order by the end time (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessInstanceEndTime
in interfaceHistoricProcessInstanceQuery
-
orderByProcessDefinitionId
public HistoricProcessInstanceQuery orderByProcessDefinitionId()
Description copied from interface:HistoricProcessInstanceQuery
Order by the process definition id (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessDefinitionId
in interfaceHistoricProcessInstanceQuery
-
orderByProcessDefinitionKey
public HistoricProcessInstanceQuery orderByProcessDefinitionKey()
Description copied from interface:HistoricProcessInstanceQuery
Order by the process definition key (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessDefinitionKey
in interfaceHistoricProcessInstanceQuery
-
orderByProcessDefinitionName
public HistoricProcessInstanceQuery orderByProcessDefinitionName()
Description copied from interface:HistoricProcessInstanceQuery
Order by the process definition name (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessDefinitionName
in interfaceHistoricProcessInstanceQuery
-
orderByProcessDefinitionVersion
public HistoricProcessInstanceQuery orderByProcessDefinitionVersion()
Description copied from interface:HistoricProcessInstanceQuery
Order by the process definition version (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessDefinitionVersion
in interfaceHistoricProcessInstanceQuery
-
orderByProcessInstanceId
public HistoricProcessInstanceQuery orderByProcessInstanceId()
Description copied from interface:HistoricProcessInstanceQuery
Order by the process instance id (needs to be followed byQuery.asc()
orQuery.desc()
).- Specified by:
orderByProcessInstanceId
in interfaceHistoricProcessInstanceQuery
-
orderByTenantId
public HistoricProcessInstanceQuery orderByTenantId()
Description copied from interface:HistoricProcessInstanceQuery
Order by tenant id (needs to be followed byQuery.asc()
orQuery.desc()
). Note that the ordering of historic process instances without tenant id is database-specific.- Specified by:
orderByTenantId
in interfaceHistoricProcessInstanceQuery
-
executeCount
public long executeCount(CommandContext commandContext)
- Specified by:
executeCount
in classAbstractVariableQueryImpl<HistoricProcessInstanceQuery,HistoricProcessInstance>
-
executeList
public java.util.List<HistoricProcessInstance> executeList(CommandContext commandContext, Page page)
Description copied from class:AbstractQuery
Executes the actual query to retrieve the list of results.- Specified by:
executeList
in classAbstractVariableQueryImpl<HistoricProcessInstanceQuery,HistoricProcessInstance>
page
- used if the results must be paged. If null, no paging will be applied.
-
executeIdsList
public java.util.List<java.lang.String> executeIdsList(CommandContext commandContext)
- Overrides:
executeIdsList
in classAbstractQuery<HistoricProcessInstanceQuery,HistoricProcessInstance>
-
executeDeploymentIdMappingsList
public java.util.List<ImmutablePair<java.lang.String,java.lang.String>> executeDeploymentIdMappingsList(CommandContext commandContext)
- Overrides:
executeDeploymentIdMappingsList
in classAbstractQuery<HistoricProcessInstanceQuery,HistoricProcessInstance>
-
getQueryVariableValues
public java.util.List<QueryVariableValue> getQueryVariableValues()
- Overrides:
getQueryVariableValues
in classAbstractVariableQueryImpl<HistoricProcessInstanceQuery,HistoricProcessInstance>
-
getQueryVariableNameToValuesMap
public java.util.Map<java.lang.String,java.util.Set<QueryVariableValue>> getQueryVariableNameToValuesMap()
-
ensureVariablesInitialized
protected void ensureVariablesInitialized()
-
addVariable
protected void addVariable(java.lang.String name, java.lang.Object value, QueryOperator operator, boolean processInstanceScope)
- Overrides:
addVariable
in classAbstractVariableQueryImpl<HistoricProcessInstanceQuery,HistoricProcessInstance>
-
getQueries
public java.util.List<HistoricProcessInstanceQueryImpl> getQueries()
-
addOrQuery
public void addOrQuery(HistoricProcessInstanceQueryImpl orQuery)
-
setOrQueryActive
public void setOrQueryActive()
-
isOrQueryActive
public boolean isOrQueryActive()
-
getActiveActivityIds
public java.lang.String[] getActiveActivityIds()
-
getBusinessKey
public java.lang.String getBusinessKey()
-
getBusinessKeyIn
public java.lang.String[] getBusinessKeyIn()
-
getBusinessKeyLike
public java.lang.String getBusinessKeyLike()
-
getExecutedActivityIds
public java.lang.String[] getExecutedActivityIds()
-
getExecutedActivityAfter
public java.util.Date getExecutedActivityAfter()
-
getExecutedActivityBefore
public java.util.Date getExecutedActivityBefore()
-
getExecutedJobAfter
public java.util.Date getExecutedJobAfter()
-
getExecutedJobBefore
public java.util.Date getExecutedJobBefore()
-
isOpen
public boolean isOpen()
-
isUnfinished
public boolean isUnfinished()
-
isFinished
public boolean isFinished()
-
getProcessDefinitionId
public java.lang.String getProcessDefinitionId()
-
getProcessDefinitionKey
public java.lang.String getProcessDefinitionKey()
-
getProcessDefinitionKeys
public java.lang.String[] getProcessDefinitionKeys()
-
getProcessDefinitionIdLike
public java.lang.String getProcessDefinitionIdLike()
-
getProcessDefinitionName
public java.lang.String getProcessDefinitionName()
-
getProcessDefinitionNameLike
public java.lang.String getProcessDefinitionNameLike()
-
getProcessInstanceId
public java.lang.String getProcessInstanceId()
-
getProcessInstanceIds
public java.util.Set<java.lang.String> getProcessInstanceIds()
-
getStartedBy
public java.lang.String getStartedBy()
-
getSuperProcessInstanceId
public java.lang.String getSuperProcessInstanceId()
-
setSuperProcessInstanceId
public void setSuperProcessInstanceId(java.lang.String superProcessInstanceId)
-
getProcessKeyNotIn
public java.util.List<java.lang.String> getProcessKeyNotIn()
-
getStartedAfter
public java.util.Date getStartedAfter()
-
getStartedBefore
public java.util.Date getStartedBefore()
-
getFinishedAfter
public java.util.Date getFinishedAfter()
-
getFinishedBefore
public java.util.Date getFinishedBefore()
-
getCaseInstanceId
public java.lang.String getCaseInstanceId()
-
getIncidentType
public java.lang.String getIncidentType()
-
getIncidentMessage
public java.lang.String getIncidentMessage()
-
getIncidentMessageLike
public java.lang.String getIncidentMessageLike()
-
getIncidentStatus
public java.lang.String getIncidentStatus()
-
getState
public java.lang.String getState()
-
getFinishDateBy
public java.util.Date getFinishDateBy()
-
getStartDateBy
public java.util.Date getStartDateBy()
-
getStartDateOn
public java.util.Date getStartDateOn()
-
getStartDateOnBegin
public java.util.Date getStartDateOnBegin()
-
getStartDateOnEnd
public java.util.Date getStartDateOnEnd()
-
getFinishDateOn
public java.util.Date getFinishDateOn()
-
getFinishDateOnBegin
public java.util.Date getFinishDateOnBegin()
-
getFinishDateOnEnd
public java.util.Date getFinishDateOnEnd()
-
isTenantIdSet
public boolean isTenantIdSet()
-
getIsTenantIdSet
public boolean getIsTenantIdSet()
-
isWithIncidents
public boolean isWithIncidents()
-
isWithRootIncidents
public boolean isWithRootIncidents()
-
startDateBy
@Deprecated public HistoricProcessInstanceQuery startDateBy(java.util.Date date)
Deprecated.Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were started as of the provided date. (Date will be adjusted to reflect midnight)- Specified by:
startDateBy
in interfaceHistoricProcessInstanceQuery
-
startDateOn
@Deprecated public HistoricProcessInstanceQuery startDateOn(java.util.Date date)
Deprecated.Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were started on the provided date.- Specified by:
startDateOn
in interfaceHistoricProcessInstanceQuery
-
finishDateBy
@Deprecated public HistoricProcessInstanceQuery finishDateBy(java.util.Date date)
Deprecated.Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were finished as of the provided date. (Date will be adjusted to reflect one second before midnight)- Specified by:
finishDateBy
in interfaceHistoricProcessInstanceQuery
-
finishDateOn
@Deprecated public HistoricProcessInstanceQuery finishDateOn(java.util.Date date)
Deprecated.Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that were finished on provided date.- Specified by:
finishDateOn
in interfaceHistoricProcessInstanceQuery
-
isRootProcessInstances
public boolean isRootProcessInstances()
-
getSubProcessInstanceId
public java.lang.String getSubProcessInstanceId()
-
getSuperCaseInstanceId
public java.lang.String getSuperCaseInstanceId()
-
getSubCaseInstanceId
public java.lang.String getSubCaseInstanceId()
-
getTenantIds
public java.lang.String[] getTenantIds()
-
executedActivityAfter
public HistoricProcessInstanceQuery executedActivityAfter(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that executed an activity after the given date.- Specified by:
executedActivityAfter
in interfaceHistoricProcessInstanceQuery
-
executedActivityBefore
public HistoricProcessInstanceQuery executedActivityBefore(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that executed an activity before the given date.- Specified by:
executedActivityBefore
in interfaceHistoricProcessInstanceQuery
-
executedJobAfter
public HistoricProcessInstanceQuery executedJobAfter(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that executed an job after the given date.- Specified by:
executedJobAfter
in interfaceHistoricProcessInstanceQuery
-
executedJobBefore
public HistoricProcessInstanceQuery executedJobBefore(java.util.Date date)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that executed an job before the given date.- Specified by:
executedJobBefore
in interfaceHistoricProcessInstanceQuery
-
executedActivityIdIn
public HistoricProcessInstanceQuery executedActivityIdIn(java.lang.String... ids)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that executed activities with given ids.- Specified by:
executedActivityIdIn
in interfaceHistoricProcessInstanceQuery
-
activeActivityIdIn
public HistoricProcessInstanceQuery activeActivityIdIn(java.lang.String... ids)
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that have active activities with given ids.- Specified by:
activeActivityIdIn
in interfaceHistoricProcessInstanceQuery
-
active
public HistoricProcessInstanceQuery active()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are active.- Specified by:
active
in interfaceHistoricProcessInstanceQuery
-
suspended
public HistoricProcessInstanceQuery suspended()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are suspended.- Specified by:
suspended
in interfaceHistoricProcessInstanceQuery
-
completed
public HistoricProcessInstanceQuery completed()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are completed.- Specified by:
completed
in interfaceHistoricProcessInstanceQuery
-
externallyTerminated
public HistoricProcessInstanceQuery externallyTerminated()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are externallyTerminated.- Specified by:
externallyTerminated
in interfaceHistoricProcessInstanceQuery
-
internallyTerminated
public HistoricProcessInstanceQuery internallyTerminated()
Description copied from interface:HistoricProcessInstanceQuery
Only select historic process instances that are internallyTerminated.- Specified by:
internallyTerminated
in interfaceHistoricProcessInstanceQuery
-
or
public HistoricProcessInstanceQuery or()
Description copied from interface:HistoricProcessInstanceQuery
After calling or(), a chain of several filter criteria could follow. Each filter criterion that follows or() will be linked together with an OR expression until the OR query is terminated. To terminate the OR query right after the last filter criterion was applied,
HistoricProcessInstanceQuery.endOr()
must be invoked.- Specified by:
or
in interfaceHistoricProcessInstanceQuery
- Returns:
- an object of the type
HistoricProcessInstanceQuery
on which an arbitrary amount of filter criteria could be applied. The several filter criteria will be linked together by an OR expression.
-
endOr
public HistoricProcessInstanceQuery endOr()
Description copied from interface:HistoricProcessInstanceQuery
endOr() terminates an OR query on which an arbitrary amount of filter criteria were applied. To terminate the OR query which has been started by invoking
HistoricProcessInstanceQuery.or()
, endOr() must be invoked. Filter criteria which are applied after calling endOr() are linked together by an AND expression.- Specified by:
endOr
in interfaceHistoricProcessInstanceQuery
- Returns:
- an object of the type
HistoricProcessInstanceQuery
on which an arbitrary amount of filter criteria could be applied. The filter criteria will be linked together by an AND expression.
-
-