FirstServlet.java
public class FirstServlet implements javax.servlet.Servlet
{
public void init(javax.servlet.ServletConfig sc) throws javax.servlet.ServletException
{
System.out.println("In init");
}
public void service(javax.servlet.ServletRequest req,javax.servlet.ServletResponse res) throws javax.servlet.ServletException,java.io.IOException
{
System.out.println("In service");
java.io.PrintWriter out=res.getWriter();
out.println("Hello from First Servlet");
}
public void destroy()
{
System.out.println("In destroy");
}//destroy
public String getServletInfo()
{
return "FirstServlet";
}
public javax.servlet.ServletConfig getServletConfig()
{
//should return ServletConfig
return null;
}//getServletConfig
}//class