com.acsinet_solutions.cetia4.controller
Interface ServletRequestContext

All Superinterfaces:
ActionContext, MultipartContext, ParameterAccessor, RenderContext, RequestContext
All Known Implementing Classes:
AbstractServletRequestContext, WebServiceServletRequestContext, WebServletRequestContext

public interface ServletRequestContext
extends RenderContext, ActionContext, MultipartContext

This class defines a context that implements all RenderContext, ActionContext and MultipartContext methods, and define additional methods relevant for servlet environments. Any render or action method in a framework module ( REST servlet, REST nested module ) that need to explicitly handle servlet API related features may use this interface declaration as first parameter in their render() or action methods instead of RenderContext, ActionContext and MultipartContext. This is possible so the entire servlet API is then accessible to any component, but discouraged if a generic method is available instead ( like using getRequestAttribute() generic method, for example ).

This means a render() method in a rest servlet may be coded like this: public String render( ServletRequestContext context ) instead of using RenderContext as the first parameter type. The same applies to action and multipart methods.

Today RenderContext, ActionContext and MultipartContext do not cover all of the methods in the servlet API, just the most common cases. With time, more extensive coverage will be done in these generic interfaces, to avoid accessing directly the underlying objects most of the time.

Author:
Santiago Arriaga

Method Summary
 javax.servlet.ServletConfig getServletConfig()
          Get a reference to the servlet config
 javax.servlet.ServletContext getServletContext()
          Get a reference to the servlet context
 javax.servlet.http.HttpServletRequest getServletRequest()
          Get a reference to the servlet request.
 javax.servlet.http.HttpServletResponse getServletResponse()
          Get a reference to the servlet response.
 javax.servlet.http.HttpSession getServletSession()
          Get a reference to the servlet session
 
Methods inherited from interface com.acsinet_solutions.cetia4.controller.RenderContext
display, getNavigationLink, isNewForm
 
Methods inherited from interface com.acsinet_solutions.cetia4.controller.MultipartContext
getItems
 

Method Detail

getServletConfig

javax.servlet.ServletConfig getServletConfig()
Get a reference to the servlet config


getServletContext

javax.servlet.ServletContext getServletContext()
Get a reference to the servlet context


getServletSession

javax.servlet.http.HttpSession getServletSession()
Get a reference to the servlet session


getServletRequest

javax.servlet.http.HttpServletRequest getServletRequest()
Get a reference to the servlet request.


getServletResponse

javax.servlet.http.HttpServletResponse getServletResponse()
Get a reference to the servlet response.