use of org.kie.workbench.common.stunner.bpmn.definition.property.task.MultipleInstanceExecutionMode in project kie-wb-common by kiegroup.
the class GenericServiceTaskExecutionSetTest method testEqualFalse.
@Test
public void testEqualFalse() {
GenericServiceTaskExecutionSet a = new GenericServiceTaskExecutionSet();
GenericServiceTaskExecutionSet b = new GenericServiceTaskExecutionSet();
a.setGenericServiceTaskInfo(null);
assertNotEquals(a, b);
GenericServiceTaskExecutionSet c = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_1));
GenericServiceTaskExecutionSet d = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_2));
assertNotEquals(c, d);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.MultipleInstanceExecutionMode in project kie-wb-common by kiegroup.
the class GenericServiceTaskExecutionSetTest method testHashCode.
@Test
public void testHashCode() {
GenericServiceTaskExecutionSet a = new GenericServiceTaskExecutionSet();
GenericServiceTaskExecutionSet b = new GenericServiceTaskExecutionSet();
assertEquals(a.hashCode(), b.hashCode());
GenericServiceTaskExecutionSet c = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_1));
GenericServiceTaskExecutionSet d = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_1));
assertEquals(c.hashCode(), d.hashCode());
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.MultipleInstanceExecutionMode in project kie-wb-common by kiegroup.
the class GenericServiceTaskExecutionSetTest method testEquals.
@Test
public void testEquals() {
GenericServiceTaskExecutionSet a = new GenericServiceTaskExecutionSet();
GenericServiceTaskExecutionSet b = new GenericServiceTaskExecutionSet();
assertEquals(a, b);
GenericServiceTaskExecutionSet c = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_1));
GenericServiceTaskExecutionSet d = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_1));
assertEquals(c, d);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.MultipleInstanceExecutionMode in project kie-wb-common by kiegroup.
the class GenericServiceTaskExecutionSetTest method testGetSlaDueDate.
@Test
public void testGetSlaDueDate() {
GenericServiceTaskExecutionSet a = new GenericServiceTaskExecutionSet(new GenericServiceTaskInfo(), new AssignmentsInfo(), new AdHocAutostart(), new IsAsync(), new IsMultipleInstance(false), new MultipleInstanceExecutionMode(false), new MultipleInstanceCollectionInput(), new MultipleInstanceDataInput(), new MultipleInstanceCollectionOutput(), new MultipleInstanceDataOutput(), new MultipleInstanceCompletionCondition(), new OnEntryAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new OnExitAction(new ScriptTypeListValue().addValue(new ScriptTypeValue("java", ""))), new SLADueDate(SLA_DUE_DATE_1));
assertEquals(SLA_DUE_DATE_1, a.getSlaDueDate().getValue());
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.task.MultipleInstanceExecutionMode in project kie-wb-common by kiegroup.
the class BaseSubProcessConverter method convertMultiInstanceSubprocessNode.
private BpmnNode convertMultiInstanceSubprocessNode(SubProcess subProcess) {
Node<View<MultipleInstanceSubprocess>, Edge> node = delegate.factoryManager.newNode(subProcess.getId(), MultipleInstanceSubprocess.class);
MultipleInstanceSubprocess definition = node.getContent().getDefinition();
MultipleInstanceSubProcessPropertyReader p = delegate.propertyReaderFactory.ofMultipleInstance(subProcess);
definition.setGeneral(new BPMNGeneralSet(new Name(p.getName()), new Documentation(p.getDocumentation())));
definition.setExecutionSet(new MultipleInstanceSubprocessTaskExecutionSet(new MultipleInstanceExecutionMode(p.isSequential()), new MultipleInstanceCollectionInput(p.getCollectionInput()), new MultipleInstanceCollectionOutput(p.getCollectionOutput()), new MultipleInstanceDataInput(p.getDataInput()), new MultipleInstanceDataOutput(p.getDataOutput()), new MultipleInstanceCompletionCondition(p.getCompletionCondition()), new OnEntryAction(p.getOnEntryAction()), new OnExitAction(p.getOnExitAction()), new IsMultipleInstance(true), new IsAsync(p.isAsync()), new SLADueDate(p.getSlaDueDate())));
definition.setProcessData(new ProcessData(new ProcessVariables(p.getProcessVariables())));
definition.setSimulationSet(p.getSimulationSet());
definition.setAdvancedData(new AdvancedData(p.getMetaDataAttributes()));
definition.setDimensionsSet(p.getRectangleDimensionsSet());
definition.setFontSet(p.getFontSet());
definition.setBackgroundSet(p.getBackgroundSet());
node.getContent().setBounds(p.getBounds());
return BpmnNode.of(node, p);
}
Aggregations