JSP nine commonly used built-in objects

Original link: http://www.cnblogs.com/yjc1605961523/p/11120109.html

Nine built-in object
type of object usage
request javax.servlet.http.HttpServletRequest the object information representative of the client request, for receiving data transmitted to the main server via HTTP protocol
response javax.servlet.ServletResponse response representative of the response to the client mainly the JSP container treated objects back to the client
session HttpSession session objects are created automatically by the server object associated with the user request. Server generates a session object for each user, for storing information of the user, the tracking operation state of the user.
out JspWriter out objects for outputting information in a Web browser, and manage the output buffer on the application server
pageContext inherit the role JspContext pageContext object is to obtain a range of parameters of any
major role in config ServletConfig config object is to obtain server configuration information.
object represents the JSP page Object page itself, only in the JSP page is legitimate. page hidden object contains essentially the current Servlet interface reference variable, similar to Java programming in this pointer
page action exception Exception exception of objects are exceptions, which only contains isErrorPage = "true" can be used in

application ServletContext objects to information stored in the server until the server is shut down, otherwise the application objects stored information will be valid throughout the application. Compared with the session objects, application objects longer life cycle, similar to the system of "global variables."

Reproduced in: https: //www.cnblogs.com/yjc1605961523/p/11120109.html

Guess you like

Origin blog.csdn.net/weixin_30438813/article/details/94810036