org.jbpm.pvm.internal.job
Class StartProcessTimer
java.lang.Object
org.jbpm.pvm.internal.job.JobImpl
org.jbpm.pvm.internal.job.TimerImpl
org.jbpm.pvm.internal.job.StartProcessTimer
- All Implemented Interfaces:
- java.io.Serializable, Command<java.lang.Boolean>, Job, Timer
public class StartProcessTimer
- extends TimerImpl
Job that starts a new process instance of a given process definition
on a fixed duedate/periodic time.
- Author:
- Joram Barrez
- See Also:
- Serialized Form
| Fields inherited from class org.jbpm.pvm.internal.job.JobImpl |
commandDescriptor, configuration, configurationBytes, dbid, dbversion, dueDate, exception, execution, isExclusive, lockExpirationTime, lockOwner, processInstance, retries, state, STATE_ACQUIRED, STATE_ERROR, STATE_SUSPENDED, STATE_WAITING |
| Methods inherited from class org.jbpm.pvm.internal.job.JobImpl |
acquire, getCommandDescriptor, getConfiguration, getDbid, getDuedate, getDueDate, getException, getExecution, getId, getLockExpirationTime, getLockOwner, getProcessInstance, getRetries, isExclusive, release, resume, setCommandDescriptor, setConfiguration, setDbid, setDuedate, setDueDate, setException, setExclusive, setExecution, setLockExpirationTime, setLockOwner, setRetries, suspend |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
StartProcessTimer
public StartProcessTimer()
execute
public java.lang.Boolean execute(Environment environment)
throws java.lang.Exception
- Specified by:
execute in interface Command<java.lang.Boolean>- Overrides:
execute in class TimerImpl
- Throws:
java.lang.Exception
processDefinitionExists
protected boolean processDefinitionExists(Environment environment)
startProcessInstance
protected void startProcessInstance(Environment environment)
calculateDueDate
protected boolean calculateDueDate(Environment environment)
throws java.text.ParseException
- Throws:
java.text.ParseException
schedule
public void schedule()
- Overrides:
schedule in class TimerImpl
validate
public void validate()
- Overrides:
validate in class TimerImpl
getProcessDefinitionName
public java.lang.String getProcessDefinitionName()
setProcessDefinitionName
public void setProcessDefinitionName(java.lang.String processDefinitionName)
getIntervalExpression
public java.lang.String getIntervalExpression()
setIntervalExpression
public void setIntervalExpression(java.lang.String intervalExpression)
- Sets the expression that will define the interval between
two sequential process starts by this job.
Possible expression types are
Duration and CronExpression.
toString
public java.lang.String toString()
- Overrides:
toString in class TimerImpl
Copyright © 2010 JBoss Community. All Rights Reserved.