Can we write a constructor for a Servlet class ? if yes how ?
if no why not ?
Answer Posted / abhishek taneja
yes offcourse you can write a constructor for a servlet
after all it is a java class. you can simply provide but if
u do not provide then it is by default include the no
argument constructor that is used by the Init() method in
the servlet life cycle.
Is This Answer Correct ? | 11 Yes | 0 No |
Post New Answer View All Answers
Why do we have servlet listeners?
How can we upload the file to the server using servlet?
What are sessions in servlets?
What is called servlet container?
What is the inter-servlet communication?
How can we implement a jsp page?
What are all the ways for session tracking?
What are the features added in Servlet 2.5?
What does the term localization refer to?
What are different ways for servlet authentication?
What is the purpose of dispatcherservlet properties?
how to link html file to sevlet file.one name is textbox,c&c++ is cheakbox,bc&mca is radio button and one submit buttonis ok why in this programme use in servelt file
List out difference between a JavaBean from a Servlet?
What exactly are the functions of servlet?
What is the procedure of invoking different servlet in a different application?