BookCaseAction.java~7~
上传用户:toby828
上传日期:2015-06-26
资源大小:8558k
文件大小:1k
源码类别:

Jsp/Servlet

开发平台:

Java

  1. package com.action;
  2. import org.apache.struts.action.ActionMapping;
  3. import org.apache.struts.action.ActionForm;
  4. import javax.servlet.http.HttpServletRequest;
  5. import javax.servlet.http.HttpServletResponse;
  6. import org.apache.struts.action.ActionForward;
  7. import com.actionForm.BookCaseForm;
  8. import org.apache.struts.action.Action;
  9. import com.core.ConnDB;
  10. import com.dao.BookCaseDAO;
  11. public class BookCaseAction extends Action {
  12.     private ConnDB conn=new ConnDB();
  13.     private BookCaseDAO bookCaseDAO=new BookCaseDAO();
  14.     public ActionForward perform(ActionMapping actionMapping,
  15.                                  ActionForm actionForm,
  16.                                  HttpServletRequest servletRequest,
  17.                                  HttpServletResponse servletResponse) {
  18.         BookCaseForm bookCaseForm = (BookCaseForm) actionForm;
  19.         servletRequest.setAttribute("list",bookCaseDAO.bookCaseDAOQuery(bookCaseForm));
  20.         return actionMapping.findForward("test");
  21.     }
  22. }