Originally posted by amna amna:
So will the servlet be destroyed and not initialized?
Originally posted by amna amna:
So will the servlet be destroyed and not initialized?
I was asked this question in an interview.
Originally posted by Ben Souther:
I've been wondering why that question gets asked so much.
I guess it would make a good interview question.
SCJP1.4<br />SCWCD1.5<br />"Nothing is impossible"
The statement that has underlined specifies that nothing will happen when the container calls the destroy method.
So, does that mean that the servlet will never be destroyed?
3. Once step1/step2 is over and after servlets job is over, the container will call the destroy method and the servlet wil be removed from the container.
4. If destroy method is overridden and destroy is called from init, init process will continue even after executing the overridden destroy method
(In this case, is it possible to to override the destroy method so that the servlet is removed from the container?)
Experience and talent are independent of age
DannyBlow
I will open the floodgates of his own worst nightmare! All in a tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
|