swnglu数据库连接统struts和hinernate

源代码在线查看: insertform.java

软件大小: 1488 K
上传用户: ggh062
关键词: hinernate swnglu struts 数据库
下载地址: 免注册下载 普通下载 VIP

相关代码

				/*
				 * Generated by MyEclipse Struts
				 * Template path: templates/java/JavaClass.vtl
				 */
				package addressbook.form;
				
				import javax.servlet.http.HttpServletRequest;
				import org.apache.struts.action.ActionErrors;
				import org.apache.struts.action.ActionForm;
				import org.apache.struts.action.ActionMapping;
				import org.apache.struts.action.ActionMessage;
				
				/** 
				 * MyEclipse Struts
				 * Creation date: 04-08-2008
				 * 
				 * XDoclet definition:
				 * @struts.form name="insertForm"
				 */
				public class InsertForm extends ActionForm {
					/*
					 * Generated fields
					 */
				
					/** name property */
					private String name;
					
					/** address property */
					private String address;
				
					/** phone property */
					private String phone;
				    private String email;
				    private String province;
					
				
					
					/*
					 * Generated Methods
					 */
				
					public String getProvince() {
						return province;
					}
				
				
					public void setProvince(String province) {
						this.province = province;
					}
				
				
					/** 
					 * Method validate
					 * @param mapping
					 * @param request
					 * @return ActionErrors
					 */
					public ActionErrors validate(ActionMapping mapping,HttpServletRequest request){
						ActionErrors errors =new ActionErrors();
						if(name ==null || name.length()							errors.add("false",new ActionMessage("errors.empty.name"));
						}
						return errors;
						
					}
				
				
					/** 
					 * Method reset
					 * @param mapping
					 * @param request
					 */
					public void reset(ActionMapping mapping, HttpServletRequest request) {
						// TODO Auto-generated method stub
					}
				
					/** 
					 * Returns the name.
					 * @return String
					 */
					public String getName() {
						return name;
					}
				
					/** 
					 * Set the name.
					 * @param name The name to set
					 */
					public void setName(String name) {
						this.name = name;
					}
					/** 
					 * Returns the phone.
					 * @return String
					 */
					public String getPhone() {
						return phone;
					}
				
					/** 
					 * Set the phone.
					 * @param phone The phone to set
					 */
					public void setPhone(String phone) {
						this.phone = phone;
					}
				
					/** 
					 * Returns the address.
					 * @return String
					 */
					public String getAddress() {
						return address;
					}
				
					/** 
					 * Set the address.
					 * @param address The address to set
					 */
					public void setAddress(String address) {
						this.address = address;
					}
				
				
					public String getEmail() {
						return email;
					}
				
				
					public void setEmail(String email) {
						this.email = email;
					}
				
				
				
				
					
				
					
				}			

相关资源