FileDocCategorySizeDatePackage
SimpleCounter.javaAPI DocExample495Thu Apr 05 01:19:18 BST 2001None

SimpleCounter

public class SimpleCounter extends HttpServlet

Fields Summary
int
count
Constructors Summary
Methods Summary
public voiddoGet(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res)


       
                                  
    res.setContentType("text/plain");
    PrintWriter out = res.getWriter();
    count++;
    out.println("Since loading, this servlet has been accessed " +
                count + " times.");