implicit object

When a Container translates the JSP into a servlet,the beginning of the service method is a pile of implicit object declarations and assignments.

All of the implicit objects map to something from the Servlet/JSP API.The request implicit object ,for example ,is a reference to the HttpServletRequest object passed to the service method by the Container.

API             Implicit Object

     JspWriter           ------------           out
    HttpServletRequest   ------------         request
HttpServletResponse     ------------         response
      HttpSession        ------------         session
    ServletContext       ------------         application
      ServletConfig      ------------         config
     Throwable           ------------         exception  //it only available to designated "error pages"
    PageContext          ------------         pageContext // a PageContext encapsulates  other implicit objects ,so if you give some helper object a PageContext reference,the helper can use that reference to get references to the other implicit objects and attributes from all scopes.
       Object            ------------         page  

你可能感兴趣的:(implicit object)