public class FormServiceImpl extends ServiceImpl implements FormService
commandExecutor
Constructor and Description |
---|
FormServiceImpl() |
Modifier and Type | Method and Description |
---|---|
Object |
getRenderedStartForm(String processDefinitionId)
Rendered form generated by the default build-in form engine for starting a new process instance.
|
Object |
getRenderedStartForm(String processDefinitionId,
String engineName)
Rendered form generated by the given build-in form engine for starting a new process instance.
|
Object |
getRenderedTaskForm(String taskId)
Rendered form generated by the default build-in form engine for completing a task.
|
Object |
getRenderedTaskForm(String taskId,
String engineName)
Rendered form generated by the given build-in form engine for completing a task.
|
StartFormData |
getStartFormData(String processDefinitionId)
Retrieves all data necessary for rendering a form to start a new process instance.
|
String |
getStartFormKey(String processDefinitionId)
Retrieves a user defined reference to a start form.
|
org.camunda.bpm.engine.variable.VariableMap |
getStartFormVariables(String processDefinitionId)
Retrieves a list of all variables for rendering a start from.
|
org.camunda.bpm.engine.variable.VariableMap |
getStartFormVariables(String processDefinitionId,
Collection<String> formVariables,
boolean deserializeObjectValues)
Retrieves a list of requested variables for rendering a start from.
|
TaskFormData |
getTaskFormData(String taskId)
Retrieves all data necessary for rendering a form to complete a task.
|
String |
getTaskFormKey(String processDefinitionId,
String taskDefinitionKey)
Retrieves a user defined reference to a task form.
|
org.camunda.bpm.engine.variable.VariableMap |
getTaskFormVariables(String taskId)
Retrieves a list of all variables for rendering a task form.
|
org.camunda.bpm.engine.variable.VariableMap |
getTaskFormVariables(String taskId,
Collection<String> formVariables,
boolean deserializeObjectValues)
Retrieves a list of requested variables for rendering a task form.
|
ProcessInstance |
submitStartForm(String processDefinitionId,
Map<String,Object> properties)
Start a new process instance with the user data that was entered as properties in a start form.
|
ProcessInstance |
submitStartForm(String processDefinitionId,
String businessKey,
Map<String,Object> properties)
Start a new process instance with the user data that was entered as properties in a start form.
|
ProcessInstance |
submitStartFormData(String processDefinitionId,
Map<String,String> properties) |
ProcessInstance |
submitStartFormData(String processDefinitionId,
String businessKey,
Map<String,String> properties) |
void |
submitTaskForm(String taskId,
Map<String,Object> properties)
Completes a task with the user data that was entered as properties in a task form.
|
void |
submitTaskFormData(String taskId,
Map<String,String> properties) |
getCommandExecutor, setCommandExecutor
public Object getRenderedStartForm(String processDefinitionId)
FormService
getRenderedStartForm
in interface FormService
public Object getRenderedStartForm(String processDefinitionId, String engineName)
FormService
getRenderedStartForm
in interface FormService
public Object getRenderedTaskForm(String taskId)
FormService
getRenderedTaskForm
in interface FormService
public Object getRenderedTaskForm(String taskId, String engineName)
FormService
getRenderedTaskForm
in interface FormService
public StartFormData getStartFormData(String processDefinitionId)
FormService
getStartFormData
in interface FormService
public TaskFormData getTaskFormData(String taskId)
FormService
getTaskFormData
in interface FormService
public ProcessInstance submitStartFormData(String processDefinitionId, Map<String,String> properties)
submitStartFormData
in interface FormService
public ProcessInstance submitStartFormData(String processDefinitionId, String businessKey, Map<String,String> properties)
submitStartFormData
in interface FormService
public ProcessInstance submitStartForm(String processDefinitionId, Map<String,Object> properties)
FormService
submitStartForm
in interface FormService
public ProcessInstance submitStartForm(String processDefinitionId, String businessKey, Map<String,Object> properties)
FormService
ProcessInstanceQuery.processInstanceBusinessKey(String)
. Providing such a business
key is definitely a best practice.
Note that a business key MUST be unique for the given process definition.
Process instance from different process definition are allowed to have the
same business key.submitStartForm
in interface FormService
processDefinitionId
- the id of the process definition, cannot be null.businessKey
- a key that uniquely identifies the process instance in the context or the
given process definition.properties
- the properties to pass, can be null.public void submitTaskFormData(String taskId, Map<String,String> properties)
submitTaskFormData
in interface FormService
public void submitTaskForm(String taskId, Map<String,Object> properties)
FormService
submitTaskForm
in interface FormService
public String getStartFormKey(String processDefinitionId)
FormService
getStartFormKey
in interface FormService
public String getTaskFormKey(String processDefinitionId, String taskDefinitionKey)
FormService
Task
instances returned by any
TaskQuery
.getTaskFormKey
in interface FormService
public org.camunda.bpm.engine.variable.VariableMap getStartFormVariables(String processDefinitionId)
FormService
getStartFormVariables
in interface FormService
processDefinitionId
- the id of the process definition for which the start form should be retrieved.public org.camunda.bpm.engine.variable.VariableMap getStartFormVariables(String processDefinitionId, Collection<String> formVariables, boolean deserializeObjectValues)
FormService
getStartFormVariables
in interface FormService
processDefinitionId
- the id of the process definition for which the start form should be retrieved.formVariables
- a Collection of the names of the variables to retrieve. Allows restricting the set of retrieved variables.deserializeObjectValues
- if false object values are not deserializedpublic org.camunda.bpm.engine.variable.VariableMap getTaskFormVariables(String taskId)
FormService
Retrieves a list of all variables for rendering a task form. In addition to the task variables and process variables, the method takes into account FormData specified for the task. This allows defining default values for form fields.
A variable is resolved in the following order:
getTaskFormVariables
in interface FormService
taskId
- the id of the task for which the variables should be retrieved.public org.camunda.bpm.engine.variable.VariableMap getTaskFormVariables(String taskId, Collection<String> formVariables, boolean deserializeObjectValues)
FormService
Retrieves a list of requested variables for rendering a task form. In addition to the task variables and process variables, the method takes into account FormData specified for the task. This allows defining default values for form fields.
A variable is resolved in the following order:
getTaskFormVariables
in interface FormService
taskId
- the id of the task for which the variables should be retrieved.formVariables
- a Collection of the names of the variables to retrieve. Allows restricting the set of retrieved variables.deserializeObjectValues
- if false object values are not deserializedCopyright © 2018. All rights reserved.