addborrowform.java
来自「eclipse+struts+sqlserver 简单图书管理系统,内有文档」· Java 代码 · 共 228 行
JAVA
228 行
/*
* Generated by MyEclipse Struts
* Template path: templates/java/JavaClass.vtl
*/
package kignbi.dong.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: 01-31-2008
*
* XDoclet definition:
* @struts.form name="addBorrowForm"
*/
public class AddBorrowForm extends ActionForm {
/*
* Generated fields
*/
/**
*
*/
private static final long serialVersionUID = 1L;
/** days property */
private String days;
/** not_num property */
private String not_num;
/** dt_borrow property */
private String dt_borrow;
/** bid property */
private String bid;
/** uid property */
private String uid;
/** remark property */
private String remark;
/** dt_return property */
private String dt_return;
/** number property */
private String number;
/*
* 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((uid==null)|(uid.length()<1)){
errors.add("uid",new ActionMessage("add.borrow.nouid"));
}
if((bid==null)|(bid.length()<1)){
errors.add("bid",new ActionMessage("add.borow.nobid"));
}
if((number== null)|(number.length()<1)){
errors.add("number",new ActionMessage("add.borow.nonumber"));
}
else{
try {
if ( !(new Double(number)).isNaN()) {
int b=Integer.parseInt(number);
}
}
catch (Exception e){
errors.add("number",new ActionMessage("add.borow.formatnumber"));
}
}
return errors;
}
/**
* Method reset
* @param mapping
* @param request
*/
public void reset(ActionMapping mapping, HttpServletRequest request) {
// TODO Auto-generated method stub
}
/**
* Returns the days.
* @return String
*/
public String getDays() {
return days;
}
/**
* Set the days.
* @param days The days to set
*/
public void setDays(String days) {
this.days = days;
}
/**
* Returns the not_num.
* @return String
*/
public String getNot_num() {
return not_num;
}
/**
* Set the not_num.
* @param not_num The not_num to set
*/
public void setNot_num(String not_num) {
this.not_num = not_num;
}
/**
* Returns the dt_borrow.
* @return String
*/
public String getDt_borrow() {
return dt_borrow;
}
/**
* Set the dt_borrow.
* @param dt_borrow The dt_borrow to set
*/
public void setDt_borrow(String dt_borrow) {
this.dt_borrow = dt_borrow;
}
/**
* Returns the bid.
* @return String
*/
public String getBid() {
return bid;
}
/**
* Set the bid.
* @param bid The bid to set
*/
public void setBid(String bid) {
this.bid = bid;
}
/**
* Returns the uid.
* @return String
*/
public String getUid() {
return uid;
}
/**
* Set the uid.
* @param uid The uid to set
*/
public void setUid(String uid) {
this.uid = uid;
}
/**
* Returns the remark.
* @return String
*/
public String getRemark() {
return remark;
}
/**
* Set the remark.
* @param remark The remark to set
*/
public void setRemark(String remark) {
this.remark = remark;
}
/**
* Returns the dt_return.
* @return String
*/
public String getDt_return() {
return dt_return;
}
/**
* Set the dt_return.
* @param dt_return The dt_return to set
*/
public void setDt_return(String dt_return) {
this.dt_return = dt_return;
}
/**
* Returns the number.
* @return String
*/
public String getNumber() {
return number;
}
/**
* Set the number.
* @param number The number to set
*/
public void setNumber(String number) {
this.number = number;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?