Implicit Objects in JSP

JSP provide access to some implicit object which represent some commonly used objects for servlets that JSP page developers might need to use. For example you can retrieve HTML form parameter data by using request variable, which represent the HttpServletRequest object.

Jsp Implicit Object


Following are the JSP implicit object

Implicit Object Description
requestThe HttpServletRequest object associated with the request.
responseThe HttpServletRequest object associated with the response that is sent back to the browser.
outThe JspWriter object associated with the output stream of the response.
sessionThe HttpSession object associated with the session for the given user of request.
applicationThe ServletContext object for the web application.
configThe ServletConfig object associated with the servlet for current JSP page.
pageContextThe PageContext object that encapsulates the enviroment of a single request for this current JSP page
pageThe page variable is equivalent to this variable of Java programming language.
exceptionThe exception object represents the Throwable object that was thrown by some other JSP page.


All of them are very useful and you will slowly get to know all of them as you will move ahead into your career working on live projects. For example: When you will create an application where in User sessions have to be created session will come into picture, request is used when you have form submissions in your application etc.

We will learn about these in details later on.