Can we define constructor in Servlet class?
Answer Posted / naveen
yes we can create a constructor
by default JVM calls default constructor.In addition to that if write both default and parameterized constructor then JVM call default one and then parameterized one
hence the ans is yes we hav to write two constuctors
no if write our own constructor one itself
| Is This Answer Correct ? | 5 Yes | 2 No |
Post New Answer View All Answers
How do you create a cookie using servlet?
how the HTML data stored in web server?
I Have A Plan to develop a Project in Struts,I want the template of struts project with Hibernate.Canany body provide me the required information?
Once the destroy() method is called by the container, will the servlet be immediately destroyed? What happens to the tasks(threads) that the servlet might be executing at that time?
What do you mean by chaining in servlet?
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
What are all the advantages of servlet over cgi?
What are the objects involved when a servlet receives a call from client?
Explain the features are in servlet 3?
How can you use a servlet to generate a plain text instead of html?
Whether thread can be used in servlets?
How can a servlet be used to generate plain text instead of html?
What’s the difference between forward() and sendredirect() methods?
What methods do you use in servlet - applet communication?
What do you mean by singlethreadmodel interface?