Class ServiceCaller

java.lang.Object
com.invirgance.convirgance.web.servlet.ServiceCaller

public class ServiceCaller extends Object
Utility class for invoking Processable services and returning their results as JSONObjects.
Author:
jbanes
  • Constructor Details

    • ServiceCaller

      public ServiceCaller()
  • Method Details

    • select

      public static Iterable<com.invirgance.convirgance.json.JSONObject> select(jakarta.servlet.http.HttpServletRequest request, String path, com.invirgance.convirgance.json.JSONObject parameters)
      Uses the service at path, processing the request and returning data. The service will utilize any relevant request parameters.
      Parameters:
      request - A HttpServletRequest
      path - A path to a service.
      parameters - The requests parameters that will be used by the service.
      Returns:
      An iterable response from the service.
      Throws:
      IllegalArgumentException - if a select service doesn't exist for the path.