Hi guys.. Well can u tell me that why there is need of
"init()" , i mean why can not we initialize the servlet object
with the help of constructors?
Thank you.
Answer Posted / neha rajpal
the very first step of creating the servlet is making its
object after until and unless you will not trigger the init
method it will be treated as simple object not the servlet
after triggering the init method it get the servlet config
init parameters and then only it is called as servlet so its
very imp to intiate the init method
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What are session variable in servlets?
What is the difference between forward () and sendredirect () functions in servlet? Explain
How to find whether a parameter exists in the request object?
How do you find out what client machine is making a request to your servlet
Can you explain in detail 'javax.servlet' package?
How to read request headers from servlets?
How will two or three servlets interact or communicate with each other?
What’s the use of the servlet wrapper classes??
What are the benefits of using servlet over cgi?
What are the drawbacks of cgi?
What is the process to implement doget and dopost methods?
What is httpservlet and how it is different from genericservlet?
Is servlet a framework?
Which interface must be implemented by all servlets?
What is the structure of the http response