1 18 19 20 package org.apache.struts.mock; 21 22 23 import java.util.HashMap ; 24 import java.util.Map ; 25 import org.apache.struts.action.ActionForm; 26 27 28 33 34 public class MockFormBean extends ActionForm { 35 36 37 public MockFormBean() { 38 this(null); 39 } 40 41 42 public MockFormBean(String stringProperty) { 43 this.stringProperty = stringProperty; 44 } 45 46 47 protected boolean booleanProperty = false; 48 49 public boolean getBooleanProperty() { 50 return (this.booleanProperty); 51 } 52 53 public void setBooleanProperty(boolean booleanProperty) { 54 this.booleanProperty = booleanProperty; 55 } 56 57 58 public Map getMapProperty() { 59 HashMap map = new HashMap (); 60 map.put("foo1", "bar1"); 61 map.put("foo2", "bar2"); 62 return (map); 63 } 64 65 66 protected String stringProperty = null; 67 68 public String getStringProperty() { 69 return (this.stringProperty); 70 } 71 72 public void setStringProperty(String stringProperty) { 73 this.stringProperty = stringProperty; 74 } 75 76 77 } 78 | Popular Tags |