1
2
3
4 package org.ieee.shinobu.demo.velocity.shankar;
5
6 import javax.servlet.http.HttpServletRequest;
7 import javax.servlet.http.HttpServletResponse;
8
9 import org.apache.struts.action.Action;
10 import org.apache.struts.action.ActionForm;
11 import org.apache.struts.action.ActionForward;
12 import org.apache.struts.action.ActionMapping;
13
14 /***
15 * @author shinobu
16 */
17 public class DynamicAction extends Action {
18
19
20
21
22 public ActionForward execute(ActionMapping mapping, ActionForm form,
23 HttpServletRequest request, HttpServletResponse response) throws Exception {
24 DynamicActionForm myForm = (DynamicActionForm) form;
25 System.out.println("myForm.searchCriteria:"+myForm.getValue("searchCriteria"));
26 System.out.println("myForm.searchType:"+myForm.getValue("searchType"));
27 return mapping.findForward("search");
28 }
29
30 }