use of org.jbpm.process.core.Work in project jbpm by kiegroup.
the class HumanTaskNodeHandler method writeNode.
public void writeNode(Node node, StringBuilder xmlDump, boolean includeMeta) {
WorkItemNode workItemNode = (WorkItemNode) node;
writeNode("humanTask", workItemNode, xmlDump, includeMeta);
visitParameters(workItemNode, xmlDump);
xmlDump.append(">" + EOL);
if (includeMeta) {
writeMetaData(workItemNode, xmlDump);
}
Work work = workItemNode.getWork();
visitWork(work, xmlDump, includeMeta);
visitInMappings(workItemNode.getInMappings(), xmlDump);
visitOutMappings(workItemNode.getOutMappings(), xmlDump);
for (String eventType : workItemNode.getActionTypes()) {
writeActions(eventType, workItemNode.getActions(eventType), xmlDump);
}
writeTimers(workItemNode.getTimers(), xmlDump);
endNode("humanTask", xmlDump);
}
use of org.jbpm.process.core.Work in project jbpm by kiegroup.
the class ParameterHandler method start.
public Object start(final String uri, final String localName, final Attributes attrs, final ExtensibleXmlParser parser) throws SAXException {
parser.startElementBuilder(localName, attrs);
final String name = attrs.getValue("name");
emptyAttributeCheck(localName, "name", name, parser);
Work work = (Work) parser.getParent();
ParameterDefinition parameterDefinition = new ParameterDefinitionImpl();
parameterDefinition.setName(name);
work.addParameterDefinition(parameterDefinition);
return new ParameterWrapper(parameterDefinition, work);
}
use of org.jbpm.process.core.Work in project jbpm by kiegroup.
the class WorkItemNodeFactory method workName.
public WorkItemNodeFactory workName(String name) {
Work work = getWorkItemNode().getWork();
if (work == null) {
work = new WorkImpl();
getWorkItemNode().setWork(work);
}
work.setName(name);
return this;
}
use of org.jbpm.process.core.Work in project jbpm by kiegroup.
the class HumanTaskNodeFactory method comment.
public HumanTaskNodeFactory comment(String comment) {
Work work = getHumanTaskNode().getWork();
if (work == null) {
work = new WorkImpl();
getHumanTaskNode().setWork(work);
}
work.setParameter("Comment", comment);
return this;
}
use of org.jbpm.process.core.Work in project jbpm by kiegroup.
the class HumanTaskNodeFactory method actorId.
public HumanTaskNodeFactory actorId(String actorId) {
Work work = getHumanTaskNode().getWork();
if (work == null) {
work = new WorkImpl();
getHumanTaskNode().setWork(work);
}
work.setParameter("ActorId", actorId);
return this;
}
Aggregations