public abstract class JobDeclaration<S,T extends JobEntity> extends Object implements Serializable
A job declaration is associated with an activity in the process definition graph. It provides data about jobs which are to be created when executing this activity. It also acts as a factory for new Job Instances.
Jobs are of a type T and are created in the context of type S (e.g. an execution or an event subscription). An instance of the context class is handed in when a job is created.
Modifier and Type | Field and Description |
---|---|
protected ActivityImpl |
activity |
protected boolean |
exclusive |
protected String |
jobConfiguration |
protected String |
jobDefinitionId
the id of the associated persistent jobDefinitionId
|
protected String |
jobHandlerConfiguration |
protected String |
jobHandlerType |
protected ParameterValueProvider |
jobPriorityProvider |
Constructor and Description |
---|
JobDeclaration(String jobHandlerType) |
protected String jobDefinitionId
protected String jobHandlerType
protected String jobHandlerConfiguration
protected String jobConfiguration
protected boolean exclusive
protected ActivityImpl activity
protected ParameterValueProvider jobPriorityProvider
public JobDeclaration(String jobHandlerType)
public T createJobInstance(S context)
execution
- can be null in case of a timer start event.protected void postInitialize(S context, T job)
protected abstract ExecutionEntity resolveExecution(S context)
public String getJobDefinitionId()
public void setJobDefinitionId(String jobDefinitionId)
public String getJobHandlerType()
public String getJobHandlerConfiguration()
public void setJobHandlerConfiguration(String jobHandlerConfiguration)
protected boolean resolveExclusive(S context)
protected int resolveRetries(S context)
public boolean isExclusive()
public void setExclusive(boolean exclusive)
public void setJobHandlerType(String jobHandlerType)
public String getActivityId()
public ActivityImpl getActivity()
public void setActivity(ActivityImpl activity)
public ProcessDefinitionImpl getProcessDefinition()
public String getJobConfiguration()
public void setJobConfiguration(String jobConfiguration)
public ParameterValueProvider getJobPriorityProvider()
public void setJobPriorityProvider(ParameterValueProvider jobPriorityProvider)
Copyright © 2018. All rights reserved.