Search in sources :

Example 6 with WorkImpl

use of org.jbpm.process.core.impl.WorkImpl in project jbpm by kiegroup.

the class WorkItemNodeFactory method workParameterDefinition.

public WorkItemNodeFactory workParameterDefinition(String name, DataType dataType) {
    Work work = getWorkItemNode().getWork();
    if (work == null) {
        work = new WorkImpl();
        getWorkItemNode().setWork(work);
    }
    Set<ParameterDefinition> parameterDefinitions = work.getParameterDefinitions();
    parameterDefinitions.add(new ParameterDefinitionImpl(name, dataType));
    work.setParameterDefinitions(parameterDefinitions);
    return this;
}
Also used : Work(org.jbpm.process.core.Work) WorkImpl(org.jbpm.process.core.impl.WorkImpl) ParameterDefinitionImpl(org.jbpm.process.core.impl.ParameterDefinitionImpl) ParameterDefinition(org.jbpm.process.core.ParameterDefinition)

Example 7 with WorkImpl

use of org.jbpm.process.core.impl.WorkImpl in project jbpm by kiegroup.

the class HumanTaskNodeFactory method priority.

public HumanTaskNodeFactory priority(String priority) {
    Work work = getHumanTaskNode().getWork();
    if (work == null) {
        work = new WorkImpl();
        getHumanTaskNode().setWork(work);
    }
    work.setParameter("Priority", priority);
    return this;
}
Also used : Work(org.jbpm.process.core.Work) WorkImpl(org.jbpm.process.core.impl.WorkImpl)

Example 8 with WorkImpl

use of org.jbpm.process.core.impl.WorkImpl in project jbpm by kiegroup.

the class HumanTaskNodeFactory method content.

public HumanTaskNodeFactory content(String content) {
    Work work = getHumanTaskNode().getWork();
    if (work == null) {
        work = new WorkImpl();
        getHumanTaskNode().setWork(work);
    }
    work.setParameter("Content", content);
    return this;
}
Also used : Work(org.jbpm.process.core.Work) WorkImpl(org.jbpm.process.core.impl.WorkImpl)

Example 9 with WorkImpl

use of org.jbpm.process.core.impl.WorkImpl in project jbpm by kiegroup.

the class HumanTaskNodeFactory method taskName.

public HumanTaskNodeFactory taskName(String taskName) {
    Work work = getHumanTaskNode().getWork();
    if (work == null) {
        work = new WorkImpl();
        getHumanTaskNode().setWork(work);
    }
    work.setParameter("TaskName", taskName);
    return this;
}
Also used : Work(org.jbpm.process.core.Work) WorkImpl(org.jbpm.process.core.impl.WorkImpl)

Example 10 with WorkImpl

use of org.jbpm.process.core.impl.WorkImpl in project jbpm by kiegroup.

the class HumanTaskNodeFactory method skippable.

public HumanTaskNodeFactory skippable(boolean skippable) {
    Work work = getHumanTaskNode().getWork();
    if (work == null) {
        work = new WorkImpl();
        getHumanTaskNode().setWork(work);
    }
    work.setParameter("Skippable", Boolean.toString(skippable));
    return this;
}
Also used : Work(org.jbpm.process.core.Work) WorkImpl(org.jbpm.process.core.impl.WorkImpl)

Aggregations

Work (org.jbpm.process.core.Work)23 WorkImpl (org.jbpm.process.core.impl.WorkImpl)23 RuleFlowProcess (org.jbpm.ruleflow.core.RuleFlowProcess)10 WorkItemNode (org.jbpm.workflow.core.node.WorkItemNode)10 EndNode (org.jbpm.workflow.core.node.EndNode)8 StartNode (org.jbpm.workflow.core.node.StartNode)8 ArrayList (java.util.ArrayList)7 Variable (org.jbpm.process.core.context.variable.Variable)6 ObjectDataType (org.jbpm.process.core.datatype.impl.type.ObjectDataType)6 DroolsConsequenceAction (org.jbpm.workflow.core.impl.DroolsConsequenceAction)5 ActionNode (org.jbpm.workflow.core.node.ActionNode)5 ParameterDefinition (org.jbpm.process.core.ParameterDefinition)4 ParameterDefinitionImpl (org.jbpm.process.core.impl.ParameterDefinitionImpl)4 HashSet (java.util.HashSet)3 IntegerDataType (org.jbpm.process.core.datatype.impl.type.IntegerDataType)3 StringDataType (org.jbpm.process.core.datatype.impl.type.StringDataType)3 DroolsAction (org.jbpm.workflow.core.DroolsAction)3 ConnectionImpl (org.jbpm.workflow.core.impl.ConnectionImpl)3 KnowledgeBuilderImpl (org.drools.compiler.builder.impl.KnowledgeBuilderImpl)2 ProcessBuilderImpl (org.jbpm.compiler.ProcessBuilderImpl)2