Interface ExecutionResult


public interface ExecutionResult
Result of a bpm process execution
Since:
9.1
API:
This is a public API.
  • Method Summary

    Modifier and Type
    Method
    Description
    Provides access to occurred bpm error.
    Provides the process data of the executed process
    Use the history to assert the process elements that were executed
    Provides access to the http response.
    Provides the result of the callable sub process that was executed.
    Returns null if no sub process was called or the sub process threw a bpm error.
    Provides access to the workflow data like task and case.
  • Method Details

    • history

      History history()
      Use the history to assert the process elements that were executed

      Example:

      
       var startElement = BpmElement.processName("processUnderTest").name("start.ivp");
       var endElement = BpmElement.processName("processUnderTest").name("end");
       var result = bpmClient.start().process(startElement).execute();
       assertThat(result.history().elements()).contains(startEelement, endElement);
       
      Returns:
      history
      API:
      This public API is available in Java.
    • data

      ProcessData data()
      Provides the process data of the executed process
      Returns:
      process data access
      API:
      This public API is available in Java.
    • workflow

      Workflow workflow()
      Provides access to the workflow data like task and case.

      Example:

      
       var startElement = BpmElement.processName("processUnderTest").name("start.ivp");
       var result = bpmClient.start().process(startElement).as().anonymous().execute();
       assertThat(result.workflow().session().isSessionUserUnknown()).isTrue();
       assertThat(result.workflow().executedTask().getState()).isEqualTo(TaskState.DONE);
       
      Returns:
      workflow access
      API:
      This public API is available in Java.
    • http

      HttpResponse http()
      Provides access to the http response.

      Example:

      
       var startElement = BpmElement.processName("processUnderTest").name("start.ivp");
       var result = bpmClient.start().process(startElement).execute();
       assertThat(result.http().redirectLocation()).contains("customEndPage.html")
       
      Returns:
      http response access
      API:
      This public API is available in Java.
    • bpmError

      BpmError bpmError()
      Provides access to occurred bpm error. Process needs to be executed with @RequestBuilder.executeAndIgnoreBpmError()

      Example:

      
       var startElement = BpmElement.processName("processUnderTest").name("start.ivp");
       var result = bpmClient.start().process(startElement).executeAndIgnoreBpmError();
       assertThat(result.bpmError().getErrorCode()).isEqualTo("ivy:error");
       
      Returns:
      bpmError
      API:
      This public API is available in Java.
    • subResult

      Provides the result of the callable sub process that was executed.
      Returns null if no sub process was called or the sub process threw a bpm error.

      Returns:
      result of the callable sub process. Can be null.
      Since:
      9.2
      See Also:
      API:
      This public API is available in Java.