public class ProcessController extends Controller
This allows simplified access to starting and concluding a process under program control.
As this extends Controller, all Controller capabilities are available.
TaskController
Controller.ControllerException, Controller.LogElement, Controller.LogLevel
Modifier and Type | Field and Description |
---|---|
protected java.lang.Long |
targetProcessId |
defaultDuration, defaultTimeUnit, log, LOG, logLevel, logToLogger, performance, sc
Constructor and Description |
---|
ProcessController(ServiceContext sc,
java.lang.Long targetProcessId)
Construct a ProcessController for the given ServiceContext.
|
Modifier and Type | Method and Description |
---|---|
int |
concludeProcess()
Conclude process will return whenever the target process is no longer active.
|
int |
concludeProcess(long duration,
java.util.concurrent.TimeUnit timeUnit)
Conclude process will return whenever the target process is no longer active.
|
java.lang.Long |
startProcess(java.lang.Long processModelId,
ProcessVariable[] pvs)
Start the given ProcessModel using the given ProcessVariables.
|
clearLog, enableLogToLogger, enablePerformanceLogging, getLog, getPerformanceSummary, log, setLogLevel, setTimeout, yield
public ProcessController(ServiceContext sc, java.lang.Long targetProcessId)
sc
- activityId
- public java.lang.Long startProcess(java.lang.Long processModelId, ProcessVariable[] pvs) throws InvalidProcessModelException, PrivilegeException, InvalidStateException, StorageLimitException, InvalidUserException, java.lang.IllegalArgumentException, java.lang.Exception
processModelId
- pvs
- java.lang.Exception
java.lang.IllegalArgumentException
InvalidUserException
StorageLimitException
InvalidStateException
PrivilegeException
InvalidProcessModelException
public int concludeProcess() throws InvalidProcessException, ArchivedProcessException, PrivilegeException, java.util.concurrent.TimeoutException
java.util.concurrent.TimeoutException
PrivilegeException
ArchivedProcessException
InvalidProcessException
public int concludeProcess(long duration, java.util.concurrent.TimeUnit timeUnit) throws InvalidProcessException, ArchivedProcessException, PrivilegeException, java.util.concurrent.TimeoutException
duration
- timeUnit
- PrivilegeException
ArchivedProcessException
InvalidProcessException
java.util.concurrent.TimeoutException
Copyright © 2003-2024 Appian Corporation. All Rights Reserved.