kunal
Sumit Aggarwal wrote:I recently came across a question,
If in a web container we have two applications A & B deployed and we need to send information from a servlet of application A to a servlet of application B, so that the information is not exposed to other servlets of application A or B. Which thing we should use to achive this objective.
1. HttpServletRequest
2. HttpServletResponse
3. ServletContext
4. ServletConfig
SCJP5
Swetha Bhagavathula wrote:we can use only ServletContext object because ServletContext object(object of the class which is implementin javax.servlet.ServletContext interface) is visible to the web applications residing in same web server.
Prasad Krishnegowda wrote:
Swetha Bhagavathula wrote:we can use only ServletContext object because ServletContext object(object of the class which is implementin javax.servlet.ServletContext interface) is visible to the web applications residing in same web server.
Sorry, I beg to differ on this..
ServletConfig is one per application .
SCJP5
Swetha Bhagavathula wrote:
Prasad Krishnegowda wrote:
Swetha Bhagavathula wrote:we can use only ServletContext object because ServletContext object(object of the class which is implementin javax.servlet.ServletContext interface) is visible to the web applications residing in same web server.
Sorry, I beg to differ on this..
ServletConfig is one per application .
hi..ServletConfig is one per servlet program.not one per web application
SCJP5
Prasoon Kumar Mishra wrote:you have to use servletConfig
SCJP5
SCJP5