Class HttpMethodController

java.lang.Object
com.chillycheesy.modulo.controllers.HttpMethodController
All Implemented Interfaces:
Controller

public class HttpMethodController extends Object implements Controller
Controller that test the http methods. Check if the method match with the target method.
  • Constructor Details

    • HttpMethodController

      public HttpMethodController(String method)
      Constructor.
      Parameters:
      method - the target method.
  • Method Details

    • apply

      public Object apply(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Configuration configuration) throws Exception
      Apply the controller. If the method match with the target method then return the next controller result.
      Specified by:
      apply in interface Controller
      Parameters:
      request - the http request.
      response - the http response.
      configuration - the configuration.
      Returns:
      the response.
      Throws:
      Exception
    • setNextStep

      public void setNextStep(Controller controller)
      Set the next controller.
      Specified by:
      setNextStep in interface Controller
      Parameters:
      controller - the next controller.