com.ibm.commerce.context.preview.servlet

Interface PreviewRequestPlugin

  • All Known Implementing Classes:
    ManagedFilePreviewRequestPluginImpl


    public interface PreviewRequestPlugin
    This interface defines how the preview servlet calls out to customized plug-ins. The customized plug-ins can handle the request before forwarding the request to the Stores web application. If the plug-in handles the request then the request will not be forwarded on to the Stores web application.
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String COPYRIGHT
      IBM copyright notice field.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method and Description
      boolean handleRequest(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, javax.servlet.ServletContext servletContext)
      This method handles the HTTP request.
    • Field Detail

      • COPYRIGHT

        static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
    • Method Detail

      • handleRequest

        boolean handleRequest(javax.servlet.http.HttpServletRequest request,
                              javax.servlet.http.HttpServletResponse response,
                              javax.servlet.ServletContext servletContext)
                       throws javax.servlet.ServletException,
                              java.io.IOException
        This method handles the HTTP request. If the plug-in decides to handle the request, it will populate the HTTP response object with the information needed to return the result. It will then indicate that the request was handled thus should not be passed along for further processing. If the plug-in does not handle the request then the response object cannot be modified. This method will only throw exceptions related to generating the response to the request. Exceptions occuring during processing whether the plug-in should handle the request should be caught and false should be returned.
        Parameters:
        request - The HTTP request object.
        response - The HTTP response object.
        servletContext - The servlet context of the servlet calling the plug-in.
        Returns:
        Returns whether the preview request handler handled the request. A value of true means that the plug-in has handled the request and produced a response. A value of false means to either use another plug-in to handle the request or forward the request to the stores web application for processing.
        Throws:
        javax.servlet.ServletException - A problem occurred when modifying the response object.
        java.io.IOException - A problem occurred while writing the response in the response object.