Package org.camunda.bpm.engine

Examples of org.camunda.bpm.engine.CaseService


    TaskService taskService = mock(TaskService.class);
    RuntimeService runtimeService = mock(RuntimeService.class);
    FormService formService = mock(FormService.class);
    HistoryService historyService = mock(HistoryService.class);
    ManagementService managementService = mock(ManagementService.class);
    CaseService caseService = mock(CaseService.class);
    FilterService filterService = mock(FilterService.class);

    when(engine.getRepositoryService()).thenReturn(repoService);
    when(engine.getIdentityService()).thenReturn(identityService);
    when(engine.getTaskService()).thenReturn(taskService);
View Full Code Here


  public CaseExecutionVariablesResource(ProcessEngine engine, String resourceId, ObjectMapper objectMapper) {
    super(engine, resourceId, objectMapper);
  }

  protected VariableMap getVariableEntities(boolean deserializeValues) {
    CaseService caseService = engine.getCaseService();
    return caseService.getVariablesTyped(resourceId, deserializeValues);
  }
View Full Code Here

    CaseService caseService = engine.getCaseService();
    return caseService.getVariablesTyped(resourceId, deserializeValues);
  }

  protected void updateVariableEntities(VariableMap variables, List<String> deletions) {
    CaseService caseService = engine.getCaseService();
    caseService
      .withCaseExecution(resourceId)
      .setVariables(variables)
      .removeVariables(deletions)
      .execute();
  }
View Full Code Here

      .removeVariables(deletions)
      .execute();
  }

  protected void removeVariableEntity(String variableKey) {
    CaseService caseService = engine.getCaseService();
    caseService
      .withCaseExecution(resourceId)
      .removeVariable(variableKey)
      .execute();
  }
View Full Code Here

  protected String getResourceTypeName() {
    return "case execution";
  }

  protected TypedValue getVariableEntity(String variableKey, boolean deserializeValue) {
    CaseService caseService = engine.getCaseService();
    return caseService.getVariableTyped(resourceId, variableKey, deserializeValue);
  }
View Full Code Here

    CaseService caseService = engine.getCaseService();
    return caseService.getVariableTyped(resourceId, variableKey, deserializeValue);
  }

  protected void setVariableEntity(String variableKey, TypedValue variableValue) {
    CaseService caseService = engine.getCaseService();
    caseService
      .withCaseExecution(resourceId)
      .setVariable(variableKey, variableValue)
      .execute();
  }
View Full Code Here

      IoUtil.closeSilently(caseModelInputStream);
    }
  }

  public CaseInstanceDto createCaseInstance(UriInfo context, CreateCaseInstanceDto parameters) {
    CaseService caseService = engine.getCaseService();

    CaseInstance instance = null;
    try {

      String businessKey = parameters.getBusinessKey();
      VariableMap variables = VariableValueDto.toMap(parameters.getVariables(), engine, objectMapper);

      instance = caseService
          .withCaseDefinition(caseDefinitionId)
          .businessKey(businessKey)
          .setVariables(variables)
          .create();
View Full Code Here

    this.caseInstanceId = caseInstanceId;
    this.objectMapper = objectMapper;
  }

  public CaseInstanceDto getCaseInstance() {
    CaseService caseService = engine.getCaseService();

    CaseInstance instance = caseService
        .createCaseInstanceQuery()
        .caseInstanceId(caseInstanceId)
        .singleResult();

    if (instance == null) {
View Full Code Here

    return result;
  }

  public void complete(CaseExecutionTriggerDto triggerDto) {
    try {
      CaseService caseService = engine.getCaseService();
      CaseExecutionCommandBuilder commandBuilder = caseService.withCaseExecution(caseInstanceId);

      initializeCommand(commandBuilder, triggerDto, "complete");

      commandBuilder.complete();
View Full Code Here

    }
  }

  public void close(CaseExecutionTriggerDto triggerDto) {
    try {
      CaseService caseService = engine.getCaseService();
      CaseExecutionCommandBuilder commandBuilder = caseService.withCaseExecution(caseInstanceId);

      initializeCommand(commandBuilder, triggerDto, "close");

      commandBuilder.close();
View Full Code Here

TOP

Related Classes of org.camunda.bpm.engine.CaseService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.