Search in sources :

Example 1 with OutputsCaseParameter

use of org.camunda.bpm.model.cmmn.instance.OutputsCaseParameter in project camunda-cmmn-model by camunda.

the class OutputsCaseParameterImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(OutputsCaseParameter.class, CMMN_ELEMENT_OUTPUTS).namespaceUri(CMMN10_NS).extendsType(CaseParameter.class).instanceProvider(new ModelElementTypeBuilder.ModelTypeInstanceProvider<OutputsCaseParameter>() {

        public OutputsCaseParameter newInstance(ModelTypeInstanceContext instanceContext) {
            return new OutputsCaseParameterImpl(instanceContext);
        }
    });
    typeBuilder.build();
}
Also used : OutputsCaseParameter(org.camunda.bpm.model.cmmn.instance.OutputsCaseParameter) OutputsCaseParameter(org.camunda.bpm.model.cmmn.instance.OutputsCaseParameter) CaseParameter(org.camunda.bpm.model.cmmn.instance.CaseParameter) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 2 with OutputsCaseParameter

use of org.camunda.bpm.model.cmmn.instance.OutputsCaseParameter in project camunda-cmmn-model by camunda.

the class Cmmn10Test method shouldGetTaskInputsOutputs.

@Test
public void shouldGetTaskInputsOutputs() {
    CmmnModelInstance modelInstance = getCmmnModelInstance();
    HumanTask humanTask = modelInstance.getModelElementsByType(HumanTask.class).iterator().next();
    Collection<InputsCaseParameter> inputs = humanTask.getInputs();
    assertThat(inputs).hasSize(1);
    Collection<InputCaseParameter> inputParameters = humanTask.getInputParameters();
    assertThat(inputParameters).isEmpty();
    Collection<OutputsCaseParameter> outputs = humanTask.getOutputs();
    assertThat(outputs).hasSize(1);
    Collection<OutputCaseParameter> outputParameters = humanTask.getOutputParameters();
    assertThat(outputParameters).isEmpty();
}
Also used : InputCaseParameter(org.camunda.bpm.model.cmmn.instance.InputCaseParameter) OutputsCaseParameter(org.camunda.bpm.model.cmmn.instance.OutputsCaseParameter) HumanTask(org.camunda.bpm.model.cmmn.instance.HumanTask) OutputCaseParameter(org.camunda.bpm.model.cmmn.instance.OutputCaseParameter) CmmnModelInstance(org.camunda.bpm.model.cmmn.CmmnModelInstance) InputsCaseParameter(org.camunda.bpm.model.cmmn.instance.InputsCaseParameter) Test(org.junit.Test)

Aggregations

OutputsCaseParameter (org.camunda.bpm.model.cmmn.instance.OutputsCaseParameter)2 CmmnModelInstance (org.camunda.bpm.model.cmmn.CmmnModelInstance)1 CaseParameter (org.camunda.bpm.model.cmmn.instance.CaseParameter)1 HumanTask (org.camunda.bpm.model.cmmn.instance.HumanTask)1 InputCaseParameter (org.camunda.bpm.model.cmmn.instance.InputCaseParameter)1 InputsCaseParameter (org.camunda.bpm.model.cmmn.instance.InputsCaseParameter)1 OutputCaseParameter (org.camunda.bpm.model.cmmn.instance.OutputCaseParameter)1 ModelTypeInstanceContext (org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)1 ModelElementTypeBuilder (org.camunda.bpm.model.xml.type.ModelElementTypeBuilder)1 Test (org.junit.Test)1