Class HttpResponse

java.lang.Object
ch.ivyteam.ivy.bpm.engine.client.HttpResponse

public class HttpResponse extends Object

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")
 
Since:
9.1
API:
This is a public API.
  • Method Summary

    Modifier and Type
    Method
    Description
    Retruns the content of this http process execution.
    Returns the redirect location of this http process execution.
    javax.servlet.http.HttpServletResponse
    Provides access to the http response of this process execution.
    javax.servlet.http.HttpSession
    Provides access to the http session of this process execution.
  • Method Details

    • content

      public String content()
      Retruns the content of this http process execution.

      Example:

      
       var startElement = BpmElement.processName("processUnderTest").name("start.ivp");
       var result = bpmClient.start().process(startElement).usingHttp().execute();
       assertThat(result.http().content()).contains("Auto Dialog");
       
      Returns:
      http response content
      Throws:
      IllegalStateException - if not http response is available. This can be if you disabled the http request context
      See Also:
      API:
      This public API is available in Java.
    • redirectLocation

      public String redirectLocation()
      Returns the redirect location of this http process execution.

      Example:

      
       var startElement = BpmElement.processName("processUnderTest").name("start.ivp");
       var result = bpmClient.start().process(startElement).usingHttp().execute();
       assertThat(result.http().redirectLocation()).contains("customEndPage.html")
       
      Returns:
      redirect location
      Throws:
      IllegalStateException - if not http response is available. This can be if you disabled the http request context
      See Also:
      API:
      This public API is available in Java.
    • response

      public javax.servlet.http.HttpServletResponse response()
      Provides access to the http response of this process execution.
      Returns:
      http servlet response
      Throws:
      IllegalStateException - if not http response is available. This can be if you disabled the http request context
      See Also:
      API:
      This public API is available in Java.
    • session

      public javax.servlet.http.HttpSession session()
      Provides access to the http session of this process execution.
      Returns:
      http session
      Throws:
      IllegalStateException - if not http session is available. This can be if you disabled the http request context
      See Also:
      API:
      This public API is available in Java.