Answer Posted / sanjay sah
Yes, we can create constructor for servlet but that one
should be public no-args constructor.
If we do not create then compiler itself takes care for
it.Servlet container creates instance of servlet by invoking
public no-agrs constructor.
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
What is the difference between the getrequestdispatcher(string path) method of javax.servlet.servletrequest interface and javax.servlet.servletcontext interface?
What do you mean by cgi?
When servlet object is created?
What is servlet looping or chaining?
How is an application exception handling is done using a servlet?
Which interface must be implemented by all servlets?
What do you mean by request dispatcher in servlet? Also explain its methods.
Why do we have servlet wrapper classes?
Is servlet synchronized?
Explain url encoding in servlet?
What is servlet mapping?
What are the different methods involved in the process of session management in servlets?
Explain the difference between a web server and a web container?
Whether we can get deadlock situation in servlets?
What’s the use of the servlet wrapper classes??