Interface HttpResponseAction

All Known Implementing Classes:
DefaultHttpResponseAction

public interface HttpResponseAction
The HttpResponseAction interface is used as a result object for SignService engines and handlers that process user requests (HttpUserRequest).

The HttpResponseAction can represent three different types of responses:

  • The user's browser should be redirected to a given URL.
  • The user's browser should be posted to a given URL with a set of parameters.
  • A response message should be written (HTTP Status 200).
Note: A HttpResponseAction instance can only represent one of the above types.
  • Method Summary

    Modifier and Type
    Method
    Description
    If the response action is that the SignService should reply to a request by sending back a 200 status with a response body this method return HttpBodyAction object that tells how the HTTP response should be constructed (filled in).
    If the response action is that a HTTP POST should be performed this method returns the HttpPostAction telling where the user's browser should be posted and with which parameters.
    If the response action is that a HTTP redirect should be performed this method returns the HttpRedirectAction telling where the user's browser should be directed.
  • Method Details

    • getRedirect

      @Nullable HttpRedirectAction getRedirect()
      If the response action is that a HTTP redirect should be performed this method returns the HttpRedirectAction telling where the user's browser should be directed.
      Returns:
      a HttpRedirectAction, or null if this is not a redirect action
    • getPost

      @Nullable HttpPostAction getPost()
      If the response action is that a HTTP POST should be performed this method returns the HttpPostAction telling where the user's browser should be posted and with which parameters.
      Returns:
      a HttpPostAction, or null if this is not a post action
    • getBody

      @Nullable HttpBodyAction getBody()
      If the response action is that the SignService should reply to a request by sending back a 200 status with a response body this method return HttpBodyAction object that tells how the HTTP response should be constructed (filled in).
      Returns:
      a HttpBodyAction, or null if this is not a response body action