1.12306项目编写:写实体类

在这里插入图片描述

证件类型实体类

package com.abc.web.domain;

/**
 * 证件类型实体类
 */
public class CertType {

	/**
	 * ID
	 */
	private Integer id;

	/**
	 * 证件类型
	 */
	private String content;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	@Override
	public String toString() {
		return "CertType [id=" + id + ", content=" + content + "]";
	}

}

城市实体类

package com.abc.web.domain;

/**
 * 城市实体类
 */
public class City {
	/**
	 * ID
	 */
	private Integer id;
	
	/**
	 * 市标识
	 */
	private String cityId;
	
	/**
	 * 市名称
	 */
	private String city;
	
	/**
	 * 省份
	 */
	private Province province;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getCityId() {
		return cityId;
	}

	public void setCityId(String cityId) {
		this.cityId = cityId;
	}

	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}

	public Province getProvince() {
		return province;
	}

	public void setProvince(Province province) {
		this.province = province;
	}

	@Override
	public String toString() {
		return "City [id=" + id + ", cityId=" + cityId + ", city=" + city
				+ ", province=" + province + "]";
	}

}

省份实体类

package com.abc.web.domain;

/**
 * 省实体类
 */
public class Province {
	/**
	 * ID
	 */
	private Integer id;

	/**
	 * 省份标识
	 */
	private String provinceId;

	/**
	 * 省份名称
	 */
	private String province;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getProvinceId() {
		return provinceId;
	}

	public void setProvinceId(String provinceId) {
		this.provinceId = provinceId;
	}

	public String getProvince() {
		return province;
	}

	public void setProvince(String province) {
		this.province = province;
	}

	@Override
	public String toString() {
		return "Province [id=" + id + ", provinceId=" + provinceId
				+ ", province=" + province + "]";
	}

}

用户实体类

package com.abc.web.domain;

import java.util.Date;

/**
 * 用户体类
 */
public class User {

	/**
	 * ID
	 */
	private Integer id;

	/**
	 * 用户名
	 */
	private String username;

	/**
	 * 密码
	 */
	private String password;

	/**
	 * 确认密码
	 */
	private String password2;

	/**
	 * 权限(1、管理员 2、普通用户)
	 */
	private String rule;

	/**
	 * 真实姓名
	 */
	private String realname;

	/**
	 * 性别(1、男 2、女)
	 */
	private String sex;

	/**
	 * 市信息
	 */
	private City city;

	/**
	 * 证件类型
	 */
	private CertType certType;

	/**
	 * 证件号码
	 */
	private String cert;

	/**
	 * 生日
	 */
	private Date birthday;

	/**
	 * 旅客类型
	 */
	private UserType userType;

	/**
	 * 备注信息
	 */
	private String content;

	/**
	 * 用户状态(0、无效 1、有效 )
	 */
	private String status;

	/**
	 * 登陆IP
	 */
	private String loginIp;

	/**
	 * 用户头像路径
	 */
	private String imagePath;

	/**
	 * 自动登陆
	 */
	private boolean autoLogin;

	/**
	 * 验证码
	 */
	private String code;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getPassword2() {
		return password2;
	}

	public void setPassword2(String password2) {
		this.password2 = password2;
	}

	public String getRule() {
		return rule;
	}

	public void setRule(String rule) {
		this.rule = rule;
	}

	public String getRealname() {
		return realname;
	}

	public void setRealname(String realname) {
		this.realname = realname;
	}

	public String getSex() {
		return sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public City getCity() {
		return city;
	}

	public void setCity(City city) {
		this.city = city;
	}

	public CertType getCertType() {
		return certType;
	}

	public void setCertType(CertType certType) {
		this.certType = certType;
	}

	public String getCert() {
		return cert;
	}

	public void setCert(String cert) {
		this.cert = cert;
	}

	public Date getBirthday() {
		return birthday;
	}

	public void setBirthday(Date birthday) {
		this.birthday = birthday;
	}

	public UserType getUserType() {
		return userType;
	}

	public void setUserType(UserType userType) {
		this.userType = userType;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getLoginIp() {
		return loginIp;
	}

	public void setLoginIp(String loginIp) {
		this.loginIp = loginIp;
	}

	public String getImagePath() {
		return imagePath;
	}

	public void setImagePath(String imagePath) {
		this.imagePath = imagePath;
	}

	public boolean isAutoLogin() {
		return autoLogin;
	}

	public void setAutoLogin(boolean autoLogin) {
		this.autoLogin = autoLogin;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	@Override
	public String toString() {
		return "User [id=" + id + ", username=" + username + ", password="
				+ password + ", password2=" + password2 + ", rule=" + rule
				+ ", realname=" + realname + ", sex=" + sex + ", city=" + city
				+ ", certType=" + certType + ", cert=" + cert + ", birthday="
				+ birthday + ", userType=" + userType + ", content=" + content
				+ ", status=" + status + ", loginIp=" + loginIp
				+ ", imagePath=" + imagePath + ", autoLogin=" + autoLogin
				+ ", code=" + code + "]";
	}

}

旅客类型实体类

package com.abc.web.domain;

/**
 * 旅客类型实体类
 */
public class UserType {

	/**
	 * ID
	 */
	private Integer id;

	/**
	 * 旅客类型
	 */
	private String content;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	@Override
	public String toString() {
		return "UserType [id=" + id + ", content=" + content + "]";
	}

}
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值