loginform.java
来自「图书馆管理系统,用java编写,有原码,有检索,查询,修改,删除等功能」· Java 代码 · 共 97 行
JAVA
97 行
/*
* Generated by MyEclipse Struts
* Template path: templates/java/JavaClass.vtl
*/
package com.autumn.struts.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: 06-05-2008
*
* XDoclet definition:
* @struts.form name="loginForm"
*/
public class LoginForm extends ActionForm {
/*
* Generated fields
*/
/** password property */
private String password;
/** rid property */
private String rid;
/*
* Generated Methods
*/
/**
* Method validate
* @param mapping
* @param request
* @return ActionErrors
*/
public ActionErrors validate(ActionMapping mapping,
HttpServletRequest request) {
// TODO Auto-generated method stub
ActionErrors errors = new ActionErrors() ;
if(this.rid==null||"".equals(this.rid))
{
errors.add("login", new ActionMessage("rid.null")) ;
}
if(this.password==null||"".equals(this.password))
{
errors.add("login", new ActionMessage("password.null")) ;
}
return errors ;
}
/**
* Method reset
* @param mapping
* @param request
*/
public void reset(ActionMapping mapping, HttpServletRequest request) {
// TODO Auto-generated method stub
}
/**
* Returns the password.
* @return String
*/
public String getPassword() {
return password;
}
/**
* Set the password.
* @param password The password to set
*/
public void setPassword(String password) {
this.password = password;
}
/**
* Returns the rid.
* @return String
*/
public String getRid() {
return rid;
}
/**
* Set the rid.
* @param rid The rid to set
*/
public void setRid(String rid) {
this.rid = rid;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?