gadgetRequestStatServlet.java :  » Google-tech » tau10a-wave-toto » guestbook » Java Open Source

Java Open Source » Google tech » tau10a wave toto 
tau10a wave toto » guestbook » gadgetRequestStatServlet.java
package guestbook;
import java.util.List;

import javax.servlet.http.*;

/*
 * this class supports the gadget's requests for the toto site statistics links
 */

public class gadgetRequestStatServlet extends abstractRequestServlet<totoStat> 
{    
  /**
   * 
   */
  private static final long serialVersionUID = 1221402283755297122L;

  public void doGet(HttpServletRequest req, HttpServletResponse resp)
   
  {
    try
    {
      List<totoStat> list;
      String result="error";
      list=getData(totoStat.class);
      for (totoStat elem: list){
        result= elem.toString();
      }
      writeToServlet(resp,result);
    }
    catch (Exception e)
    {
      e.printStackTrace();
    } /* catches exception for the gadget*/
    finally
    {   
      pmClose();
    }
  }  
}



java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.