Class UpdateProcessDefinitionSuspensionStateBuilderImpl
java.lang.Object
org.camunda.bpm.engine.impl.repository.UpdateProcessDefinitionSuspensionStateBuilderImpl
- All Implemented Interfaces:
UpdateProcessDefinitionSuspensionStateBuilder
,UpdateProcessDefinitionSuspensionStateSelectBuilder
,UpdateProcessDefinitionSuspensionStateTenantBuilder
public class UpdateProcessDefinitionSuspensionStateBuilderImpl
extends Object
implements UpdateProcessDefinitionSuspensionStateBuilder, UpdateProcessDefinitionSuspensionStateSelectBuilder, UpdateProcessDefinitionSuspensionStateTenantBuilder
-
Field Summary
Modifier and TypeFieldDescriptionprotected final CommandExecutor
protected Date
protected boolean
protected boolean
protected String
protected String
protected String
-
Constructor Summary
ConstructorDescriptionCreates a builder without CommandExecutor which can not be used to update the suspension state viaactivate()
orsuspend()
.UpdateProcessDefinitionSuspensionStateBuilderImpl
(CommandExecutor commandExecutor) -
Method Summary
Modifier and TypeMethodDescriptionvoid
activate()
Activates the provided process definitions.byProcessDefinitionId
(String processDefinitionId) Selects the process definition with the given id.byProcessDefinitionKey
(String processDefinitionKey) Selects the process definitions with the given key.executionDate
(Date date) Specify when the suspension state should be updated.includeProcessInstances
(boolean includeProcessInstance) Specify if the suspension states of the process instances of the provided process definitions should also be updated.boolean
boolean
processDefinitionTenantId
(String tenantId) Specify the id of the tenant the process definition belongs to.Specify that the process definition belongs to no tenant.void
suspend()
Suspends the provided process definitions.protected void
-
Field Details
-
commandExecutor
-
processDefinitionKey
-
processDefinitionId
-
includeProcessInstances
protected boolean includeProcessInstances -
executionDate
-
processDefinitionTenantId
-
isTenantIdSet
protected boolean isTenantIdSet
-
-
Constructor Details
-
UpdateProcessDefinitionSuspensionStateBuilderImpl
-
UpdateProcessDefinitionSuspensionStateBuilderImpl
public UpdateProcessDefinitionSuspensionStateBuilderImpl()Creates a builder without CommandExecutor which can not be used to update the suspension state viaactivate()
orsuspend()
. Can be used in combination with your own command.
-
-
Method Details
-
byProcessDefinitionId
public UpdateProcessDefinitionSuspensionStateBuilderImpl byProcessDefinitionId(String processDefinitionId) Description copied from interface:UpdateProcessDefinitionSuspensionStateSelectBuilder
Selects the process definition with the given id.- Specified by:
byProcessDefinitionId
in interfaceUpdateProcessDefinitionSuspensionStateSelectBuilder
- Parameters:
processDefinitionId
- id of the process definition- Returns:
- the builder
-
byProcessDefinitionKey
public UpdateProcessDefinitionSuspensionStateBuilderImpl byProcessDefinitionKey(String processDefinitionKey) Description copied from interface:UpdateProcessDefinitionSuspensionStateSelectBuilder
Selects the process definitions with the given key.- Specified by:
byProcessDefinitionKey
in interfaceUpdateProcessDefinitionSuspensionStateSelectBuilder
- Parameters:
processDefinitionKey
- key of the process definition- Returns:
- the builder
-
includeProcessInstances
public UpdateProcessDefinitionSuspensionStateBuilderImpl includeProcessInstances(boolean includeProcessInstance) Description copied from interface:UpdateProcessDefinitionSuspensionStateBuilder
Specify if the suspension states of the process instances of the provided process definitions should also be updated. Default isfalse
.- Specified by:
includeProcessInstances
in interfaceUpdateProcessDefinitionSuspensionStateBuilder
- Parameters:
includeProcessInstance
- iftrue
, all related process instances will be activated / suspended too.- Returns:
- the builder
-
executionDate
Description copied from interface:UpdateProcessDefinitionSuspensionStateBuilder
Specify when the suspension state should be updated. Note that the job executor needs to be active to use this.- Specified by:
executionDate
in interfaceUpdateProcessDefinitionSuspensionStateBuilder
- Parameters:
date
- the date on which the process definition will be activated / suspended. Ifnull
, the process definition is activated / suspended immediately.- Returns:
- the builder
-
processDefinitionWithoutTenantId
Description copied from interface:UpdateProcessDefinitionSuspensionStateTenantBuilder
Specify that the process definition belongs to no tenant.- Specified by:
processDefinitionWithoutTenantId
in interfaceUpdateProcessDefinitionSuspensionStateTenantBuilder
- Returns:
- the builder
-
processDefinitionTenantId
Description copied from interface:UpdateProcessDefinitionSuspensionStateTenantBuilder
Specify the id of the tenant the process definition belongs to.- Specified by:
processDefinitionTenantId
in interfaceUpdateProcessDefinitionSuspensionStateTenantBuilder
- Parameters:
tenantId
- the id of the tenant- Returns:
- the builder
-
activate
public void activate()Description copied from interface:UpdateProcessDefinitionSuspensionStateBuilder
Activates the provided process definitions.- Specified by:
activate
in interfaceUpdateProcessDefinitionSuspensionStateBuilder
-
suspend
public void suspend()Description copied from interface:UpdateProcessDefinitionSuspensionStateBuilder
Suspends the provided process definitions. If a process definition is in state suspended, it will not be possible to start new process instances based on this process definition.- Specified by:
suspend
in interfaceUpdateProcessDefinitionSuspensionStateBuilder
-
validateParameters
protected void validateParameters() -
getProcessDefinitionKey
-
getProcessDefinitionId
-
isIncludeProcessInstances
public boolean isIncludeProcessInstances() -
getExecutionDate
-
getProcessDefinitionTenantId
-
isTenantIdSet
public boolean isTenantIdSet()
-