This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Servlets and the fly likes Why be use init method Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Reply locked New topic
Author

Why be use init method

rinku jain
Greenhorn

Joined: Jan 04, 2011
Posts: 26
what is the use of init method ???
initialization of servlet code can also be done within
constructor
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

http://www.coderanch.com/how-to/java/ServletsFaq#lifecycle


[LEARNING bLOG] | [Freelance Web Designer] | [and "Rohan" is part of my surname]
 
Consider Paul's rocket mass heater.
 
subject: Why be use init method
 
Similar Threads
loading of static attributtes
getInitParameter method in ServletContext and ServletConfig
Servlet's init() and destroy() method and constructors
init(servletconfig)
Difference between init and servlet constructor