Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

can v create a constructor 4 servlet?

Answer Posted / paidi

Yes, It can possible to create the constructor inside the
servlet , it wont give any exception or error for creation
and it compile properly. But, Servlet initialization will
done by container. Container calls the init() to
initialize the servletconfg obj. No Use to write the
constructor inside the servlet.

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between get and post methods?

1026


What is the structure of the http response

1157


What is the use of servlet context?

1029


Can we use threads in Servlets?

1126


Is it good idea to create servlet constructor?

1235


Why do we need a constructor in a servlet if we use the init method?

1032


How can we invoke another servlet in a different application?

1189


What is the major difference between context parameter and context attribute?

1089


Elucidate servlet attributes and its scope?

991


When should you prefer to use doget() over dopost()?

1133


How do you design microservices?

1053


Can you call a jsp from the servlet?

1003


What do you mean by session tracking?

1192


What is called Session Tracking?

1174


What are the important functions of filters?

1124