本文整理汇总了Java中org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity.getSuperCaseExecutionId方法的典型用法代码示例。如果您正苦于以下问题:Java CaseExecutionEntity.getSuperCaseExecutionId方法的具体用法?Java CaseExecutionEntity.getSuperCaseExecutionId怎么用?Java CaseExecutionEntity.getSuperCaseExecutionId使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity
的用法示例。
在下文中一共展示了CaseExecutionEntity.getSuperCaseExecutionId方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: testCallCaseAsConstant
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
@Deployment(resources = {
"org/camunda/bpm/engine/test/api/cmmn/oneCaseTaskCase.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseAsConstant() {
// given
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
}
示例2: testCallCaseAsExpressionStartsWithDollar
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallCaseAsExpressionStartsWithDollar.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseAsExpressionStartsWithDollar() {
// given
// a deployed case definition
VariableMap vars = new VariableMapImpl();
vars.putValue("oneTaskCase", ONE_TASK_CASE);
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE, vars).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
}
示例3: testCallCaseAsExpressionStartsWithHash
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallCaseAsExpressionStartsWithHash.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseAsExpressionStartsWithHash() {
// given
// a deployed case definition
VariableMap vars = new VariableMapImpl();
vars.putValue("oneTaskCase", ONE_TASK_CASE);
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE, vars).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
}
示例4: testInputBusinessKey
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
/**
* assertion on default behaviour - remove manual activation
*/
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testInputBusinessKey.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testInputBusinessKey() {
// given
String businessKey = "myBusinessKey";
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE, businessKey).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals(businessKey, subCaseInstance.getBusinessKey());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
}
示例5: testInputDifferentBusinessKey
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
/**
* variable passed in manual activation - change process definition
*/
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testInputDifferentBusinessKey.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testInputDifferentBusinessKey() {
// given
String businessKey = "myBusinessKey";
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE, businessKey).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
// when
caseService
.withCaseExecution(caseTaskId)
.setVariable("myOwnBusinessKey", "myOwnBusinessKey")
.manualStart();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals("myOwnBusinessKey", subCaseInstance.getBusinessKey());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
}
示例6: testCallLatestCase
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
/**
* assert on default behaviour - remove manual activation
*/
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallLatestCase.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallLatestCase() {
// given
String cmmnResourceName = "org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn";
String deploymentId = repositoryService.createDeployment()
.addClasspathResource(cmmnResourceName)
.deploy()
.getId();
assertEquals(3, repositoryService.createCaseDefinitionQuery().count());
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
String latestCaseDefinitionId = repositoryService
.createCaseDefinitionQuery()
.caseDefinitionKey(ONE_TASK_CASE)
.latestVersion()
.singleResult()
.getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals(latestCaseDefinitionId, subCaseInstance.getCaseDefinitionId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
repositoryService.deleteDeployment(deploymentId, true);
}
示例7: testCallCaseByDeployment
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
/**
* default behaviour of manual activation changed - remove manual activation
*/
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallCaseByDeployment.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseByDeployment() {
// given
String firstDeploymentId = repositoryService
.createDeploymentQuery()
.singleResult()
.getId();
String cmmnResourceName = "org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn";
String deploymentId = repositoryService.createDeployment()
.addClasspathResource(cmmnResourceName)
.deploy()
.getId();
assertEquals(3, repositoryService.createCaseDefinitionQuery().count());
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
String caseDefinitionIdInSameDeployment = repositoryService
.createCaseDefinitionQuery()
.caseDefinitionKey(ONE_TASK_CASE)
.deploymentId(firstDeploymentId)
.singleResult()
.getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals(caseDefinitionIdInSameDeployment, subCaseInstance.getCaseDefinitionId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
repositoryService.deleteDeployment(deploymentId, true);
}
示例8: testCallCaseByVersion
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
/**
* assertions on completion - take manual activation out
*/
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallCaseByVersion.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseByVersion() {
// given
String bpmnResourceName = "org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn";
String secondDeploymentId = repositoryService.createDeployment()
.addClasspathResource(bpmnResourceName)
.deploy()
.getId();
String thirdDeploymentId = repositoryService.createDeployment()
.addClasspathResource(bpmnResourceName)
.deploy()
.getId();
assertEquals(4, repositoryService.createCaseDefinitionQuery().count());
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
String caseDefinitionIdInSecondDeployment = repositoryService
.createCaseDefinitionQuery()
.caseDefinitionKey(ONE_TASK_CASE)
.deploymentId(secondDeploymentId)
.singleResult()
.getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals(caseDefinitionIdInSecondDeployment, subCaseInstance.getCaseDefinitionId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
repositoryService.deleteDeployment(secondDeploymentId, true);
repositoryService.deleteDeployment(thirdDeploymentId, true);
}
示例9: testCallCaseByVersionAsExpressionStartsWithDollar
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallCaseByVersionAsExpressionStartsWithDollar.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseByVersionAsExpressionStartsWithDollar() {
// given
String bpmnResourceName = "org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn";
String secondDeploymentId = repositoryService.createDeployment()
.addClasspathResource(bpmnResourceName)
.deploy()
.getId();
String thirdDeploymentId = repositoryService.createDeployment()
.addClasspathResource(bpmnResourceName)
.deploy()
.getId();
assertEquals(4, repositoryService.createCaseDefinitionQuery().count());
VariableMap vars = new VariableMapImpl();
vars.putValue("myVersion", 2);
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE,vars).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
String caseDefinitionIdInSecondDeployment = repositoryService
.createCaseDefinitionQuery()
.caseDefinitionKey(ONE_TASK_CASE)
.deploymentId(secondDeploymentId)
.singleResult()
.getId();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals(caseDefinitionIdInSecondDeployment, subCaseInstance.getCaseDefinitionId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
repositoryService.deleteDeployment(secondDeploymentId, true);
repositoryService.deleteDeployment(thirdDeploymentId, true);
}
示例10: testCallCaseByVersionAsExpressionStartsWithHash
import org.camunda.bpm.engine.impl.cmmn.entity.runtime.CaseExecutionEntity; //导入方法依赖的package包/类
@Deployment(resources = {
"org/camunda/bpm/engine/test/cmmn/casetask/CaseTaskTest.testCallCaseByVersionAsExpressionStartsWithHash.cmmn",
"org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn"
})
public void testCallCaseByVersionAsExpressionStartsWithHash() {
// given
String bpmnResourceName = "org/camunda/bpm/engine/test/api/cmmn/oneTaskCase.cmmn";
String secondDeploymentId = repositoryService.createDeployment()
.addClasspathResource(bpmnResourceName)
.deploy()
.getId();
String thirdDeploymentId = repositoryService.createDeployment()
.addClasspathResource(bpmnResourceName)
.deploy()
.getId();
assertEquals(4, repositoryService.createCaseDefinitionQuery().count());
String superCaseInstanceId = createCaseInstanceByKey(ONE_CASE_TASK_CASE).getId();
String caseTaskId = queryCaseExecutionByActivityId(CASE_TASK).getId();
String caseDefinitionIdInSecondDeployment = repositoryService
.createCaseDefinitionQuery()
.caseDefinitionKey(ONE_TASK_CASE)
.deploymentId(secondDeploymentId)
.singleResult()
.getId();
// when
caseService
.withCaseExecution(caseTaskId)
.setVariable("myVersion", 2)
.manualStart();
// then
CaseExecutionEntity subCaseInstance = (CaseExecutionEntity) queryOneTaskCaseInstance();
assertNotNull(subCaseInstance);
String superCaseExecutionId = subCaseInstance.getSuperCaseExecutionId();
CaseExecution superCaseExecution = queryCaseExecutionById(superCaseExecutionId);
assertEquals(caseTaskId, superCaseExecutionId);
assertEquals(superCaseInstanceId, superCaseExecution.getCaseInstanceId());
assertEquals(caseDefinitionIdInSecondDeployment, subCaseInstance.getCaseDefinitionId());
// complete ////////////////////////////////////////////////////////
terminate(subCaseInstance.getId());
close(subCaseInstance.getId());
assertCaseEnded(subCaseInstance.getId());
terminate(caseTaskId);
close(superCaseInstanceId);
assertCaseEnded(superCaseInstanceId);
repositoryService.deleteDeployment(secondDeploymentId, true);
repositoryService.deleteDeployment(thirdDeploymentId, true);
}