public class TaskWrapper extends Object implements org.camunda.bpm.engine.task.Task
Task, providing the ability of dynamically adding
FieldDefinitions based on the TaskFormData that has been defined for that
task.Datasource.| Constructor and Description |
|---|
TaskWrapper() |
TaskWrapper(org.camunda.bpm.engine.task.Task task,
Collection<org.camunda.bpm.engine.task.IdentityLink> identityLinks,
org.camunda.bpm.engine.variable.VariableMap variables)
Create a new
TaskWrapper from the given Task |
| Modifier and Type | Method and Description |
|---|---|
void |
addFormFields(FieldProcessor fp,
org.camunda.bpm.engine.form.TaskFormData taskFormData,
String mandatoryMessage)
Dynamically adds
FieldDefinitions to the given FieldProcessor, depending on the
FormFields defined at the TaskFormData. |
protected void |
addValidation(FieldDef field,
org.camunda.bpm.engine.form.FormFieldValidationConstraint validationConstraint,
String mandatoryMessage) |
protected void |
determineFieldType(org.camunda.bpm.engine.form.FormType type,
FieldDef field) |
Object |
getFormField(String name) |
void |
validate(Site site,
Application application,
Environment environment,
Options options,
Request request,
FieldProcessor fp,
org.camunda.bpm.engine.form.TaskFormData taskFormData,
String requiredMessage)
Validates this
TaskWrapper. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdelegate, getAssignee, getCaseDefinitionId, getCaseExecutionId, getCaseInstanceId, getCreateTime, getDelegationState, getDescription, getDueDate, getExecutionId, getFollowUpDate, getFormKey, getId, getName, getOwner, getParentTaskId, getPriority, getProcessDefinitionId, getProcessInstanceId, getTaskDefinitionKey, getTenantId, isSuspended, setAssignee, setCaseInstanceId, setDelegationState, setDescription, setDueDate, setFollowUpDate, setName, setOwner, setParentTaskId, setPriority, setTenantIdpublic TaskWrapper()
public TaskWrapper(org.camunda.bpm.engine.task.Task task,
Collection<org.camunda.bpm.engine.task.IdentityLink> identityLinks,
org.camunda.bpm.engine.variable.VariableMap variables)
TaskWrapper from the given Tasktask - the Task to wrap, retrieved from a TaskServiceidentityLinks - the IdentityLinks for the task, usually retrieved with
TaskService.getIdentityLinksForTask(String)variables - the variables for this Task, usually retrieved with
TaskService.getVariablesTyped(String)public void addFormFields(FieldProcessor fp, org.camunda.bpm.engine.form.TaskFormData taskFormData, String mandatoryMessage)
FieldDefinitions to the given FieldProcessor, depending on the
FormFields defined at the TaskFormData.fp - the FieldProcessortaskFormData - the TaskFormData to dynamically add the fields frommandatoryMessage - the message in case a field id mandatoryprotected void addValidation(FieldDef field, org.camunda.bpm.engine.form.FormFieldValidationConstraint validationConstraint, String mandatoryMessage)
protected void determineFieldType(org.camunda.bpm.engine.form.FormType type,
FieldDef field)
public void validate(Site site, Application application, Environment environment, Options options, Request request, FieldProcessor fp, org.camunda.bpm.engine.form.TaskFormData taskFormData, String requiredMessage)
TaskWrapper. Therefore, the FormFields returned by the TaskFormData are
checked for FormFieldValidationConstraints. If there is a required constraint, and the value
returned by getFormField(String) is null or empty for the given FormField, an
error-message as append to the FieldDefinition of that field.site - the current Siteapplication - the current Applicationenvironment - the current Environmentoptions - the current Optionsrequest - the current Requestfp - the current FieldProcessortaskFormData - the current TaskFormDatarequiredMessage - the current SiteCopyright © 2011–2020 aiticon GmbH. All rights reserved.