package com.qxgmat.data.dao.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.*;

@Table(name = "user")
public class User implements Serializable {
    @Id
    @Column(name = "`id`")
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Integer id;

    /**
     * 昵称
     */
    @Column(name = "`nickname`")
    private String nickname;

    @Column(name = "`avatar`")
    private String avatar;

    /**
     * 密码
     */
    @Column(name = "`password`")
    private String password;

    /**
     * 邮箱
     */
    @Column(name = "`email`")
    private String email;

    /**
     * 手机-区号
     */
    @Column(name = "`area`")
    private String area;

    /**
     * 手机
     */
    @Column(name = "`mobile`")
    private String mobile;

    /**
     * 微信openid：pc端
     */
    @Column(name = "`wechat_openid_pc`")
    private String wechatOpenidPc;

    /**
     * 微信openid: 公众号
     */
    @Column(name = "`wechat_openid_wechat`")
    private String wechatOpenidWechat;

    /**
     * 微信关联id
     */
    @Column(name = "`wechat_unionid`")
    private String wechatUnionid;

    /**
     * 微信公众号accessToken
     */
    @Column(name = "`wechat_access_token`")
    private String wechatAccessToken;

    /**
     * 微信公众号refresh_token
     */
    @Column(name = "`wechat_refresh_token`")
    private String wechatRefreshToken;

    /**
     * 微信公众号expireTime
     */
    @Column(name = "`wechat_expire_time`")
    private Date wechatExpireTime;

    /**
     * 实名：姓名
     */
    @Column(name = "`real_name`")
    private String realName;

    /**
     * 实名：地址
     */
    @Column(name = "`real_address`")
    private String realAddress;

    /**
     * 实名：身份ID
     */
    @Column(name = "`real_identity`")
    private String realIdentity;

    /**
     * 实名：身份证照片
     */
    @Column(name = "`real_photo`")
    private String realPhoto;

    /**
     * 实名状态：0未实名，1已实名
     */
    @Column(name = "`real_status`")
    private Integer realStatus;

    /**
     * 备考：身份
     */
    @Column(name = "`prepare_status`")
    private String prepareStatus;

    /**
     * 备考：目标分数
     */
    @Column(name = "`prepare_goal`")
    private Integer prepareGoal;

    /**
     * 备考：考试时间
     */
    @Column(name = "`prepare_examination_time`")
    private String prepareExaminationTime;

    /**
     * 备考：出分时间
     */
    @Column(name = "`prepare_score_time`")
    private Date prepareScoreTime;

    /**
     * 上次做题
     */
    @Column(name = "`latest_exercise`")
    private Integer latestExercise;

    /**
     * 上一次错题组卷
     */
    @Column(name = "`latest_error`")
    private Integer latestError;

    /**
     * 邀请用户
     */
    @Column(name = "`origin_id`")
    private Integer originId;

    /**
     * 个人邀请码
     */
    @Column(name = "`invite_code`")
    private String inviteCode;

    /**
     * 消费金额
     */
    @Column(name = "`total_money`")
    private BigDecimal totalMoney;

    /**
     * 邀请人数
     */
    @Column(name = "`invite_number`")
    private Integer inviteNumber;

    @Column(name = "`create_time`")
    private Date createTime;

    private static final long serialVersionUID = 1L;

    /**
     * @return id
     */
    public Integer getId() {
        return id;
    }

    /**
     * @param id
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * 获取昵称
     *
     * @return nickname - 昵称
     */
    public String getNickname() {
        return nickname;
    }

    /**
     * 设置昵称
     *
     * @param nickname 昵称
     */
    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    /**
     * @return avatar
     */
    public String getAvatar() {
        return avatar;
    }

    /**
     * @param avatar
     */
    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    /**
     * 获取密码
     *
     * @return password - 密码
     */
    public String getPassword() {
        return password;
    }

    /**
     * 设置密码
     *
     * @param password 密码
     */
    public void setPassword(String password) {
        this.password = password;
    }

    /**
     * 获取邮箱
     *
     * @return email - 邮箱
     */
    public String getEmail() {
        return email;
    }

    /**
     * 设置邮箱
     *
     * @param email 邮箱
     */
    public void setEmail(String email) {
        this.email = email;
    }

    /**
     * 获取手机-区号
     *
     * @return area - 手机-区号
     */
    public String getArea() {
        return area;
    }

    /**
     * 设置手机-区号
     *
     * @param area 手机-区号
     */
    public void setArea(String area) {
        this.area = area;
    }

    /**
     * 获取手机
     *
     * @return mobile - 手机
     */
    public String getMobile() {
        return mobile;
    }

    /**
     * 设置手机
     *
     * @param mobile 手机
     */
    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    /**
     * 获取微信openid：pc端
     *
     * @return wechat_openid_pc - 微信openid：pc端
     */
    public String getWechatOpenidPc() {
        return wechatOpenidPc;
    }

    /**
     * 设置微信openid：pc端
     *
     * @param wechatOpenidPc 微信openid：pc端
     */
    public void setWechatOpenidPc(String wechatOpenidPc) {
        this.wechatOpenidPc = wechatOpenidPc;
    }

    /**
     * 获取微信openid: 公众号
     *
     * @return wechat_openid_wechat - 微信openid: 公众号
     */
    public String getWechatOpenidWechat() {
        return wechatOpenidWechat;
    }

    /**
     * 设置微信openid: 公众号
     *
     * @param wechatOpenidWechat 微信openid: 公众号
     */
    public void setWechatOpenidWechat(String wechatOpenidWechat) {
        this.wechatOpenidWechat = wechatOpenidWechat;
    }

    /**
     * 获取微信关联id
     *
     * @return wechat_unionid - 微信关联id
     */
    public String getWechatUnionid() {
        return wechatUnionid;
    }

    /**
     * 设置微信关联id
     *
     * @param wechatUnionid 微信关联id
     */
    public void setWechatUnionid(String wechatUnionid) {
        this.wechatUnionid = wechatUnionid;
    }

    /**
     * 获取微信公众号accessToken
     *
     * @return wechat_access_token - 微信公众号accessToken
     */
    public String getWechatAccessToken() {
        return wechatAccessToken;
    }

    /**
     * 设置微信公众号accessToken
     *
     * @param wechatAccessToken 微信公众号accessToken
     */
    public void setWechatAccessToken(String wechatAccessToken) {
        this.wechatAccessToken = wechatAccessToken;
    }

    /**
     * 获取微信公众号refresh_token
     *
     * @return wechat_refresh_token - 微信公众号refresh_token
     */
    public String getWechatRefreshToken() {
        return wechatRefreshToken;
    }

    /**
     * 设置微信公众号refresh_token
     *
     * @param wechatRefreshToken 微信公众号refresh_token
     */
    public void setWechatRefreshToken(String wechatRefreshToken) {
        this.wechatRefreshToken = wechatRefreshToken;
    }

    /**
     * 获取微信公众号expireTime
     *
     * @return wechat_expire_time - 微信公众号expireTime
     */
    public Date getWechatExpireTime() {
        return wechatExpireTime;
    }

    /**
     * 设置微信公众号expireTime
     *
     * @param wechatExpireTime 微信公众号expireTime
     */
    public void setWechatExpireTime(Date wechatExpireTime) {
        this.wechatExpireTime = wechatExpireTime;
    }

    /**
     * 获取实名：姓名
     *
     * @return real_name - 实名：姓名
     */
    public String getRealName() {
        return realName;
    }

    /**
     * 设置实名：姓名
     *
     * @param realName 实名：姓名
     */
    public void setRealName(String realName) {
        this.realName = realName;
    }

    /**
     * 获取实名：地址
     *
     * @return real_address - 实名：地址
     */
    public String getRealAddress() {
        return realAddress;
    }

    /**
     * 设置实名：地址
     *
     * @param realAddress 实名：地址
     */
    public void setRealAddress(String realAddress) {
        this.realAddress = realAddress;
    }

    /**
     * 获取实名：身份ID
     *
     * @return real_identity - 实名：身份ID
     */
    public String getRealIdentity() {
        return realIdentity;
    }

    /**
     * 设置实名：身份ID
     *
     * @param realIdentity 实名：身份ID
     */
    public void setRealIdentity(String realIdentity) {
        this.realIdentity = realIdentity;
    }

    /**
     * 获取实名：身份证照片
     *
     * @return real_photo - 实名：身份证照片
     */
    public String getRealPhoto() {
        return realPhoto;
    }

    /**
     * 设置实名：身份证照片
     *
     * @param realPhoto 实名：身份证照片
     */
    public void setRealPhoto(String realPhoto) {
        this.realPhoto = realPhoto;
    }

    /**
     * 获取实名状态：0未实名，1已实名
     *
     * @return real_status - 实名状态：0未实名，1已实名
     */
    public Integer getRealStatus() {
        return realStatus;
    }

    /**
     * 设置实名状态：0未实名，1已实名
     *
     * @param realStatus 实名状态：0未实名，1已实名
     */
    public void setRealStatus(Integer realStatus) {
        this.realStatus = realStatus;
    }

    /**
     * 获取备考：身份
     *
     * @return prepare_status - 备考：身份
     */
    public String getPrepareStatus() {
        return prepareStatus;
    }

    /**
     * 设置备考：身份
     *
     * @param prepareStatus 备考：身份
     */
    public void setPrepareStatus(String prepareStatus) {
        this.prepareStatus = prepareStatus;
    }

    /**
     * 获取备考：目标分数
     *
     * @return prepare_goal - 备考：目标分数
     */
    public Integer getPrepareGoal() {
        return prepareGoal;
    }

    /**
     * 设置备考：目标分数
     *
     * @param prepareGoal 备考：目标分数
     */
    public void setPrepareGoal(Integer prepareGoal) {
        this.prepareGoal = prepareGoal;
    }

    /**
     * 获取备考：考试时间
     *
     * @return prepare_examination_time - 备考：考试时间
     */
    public String getPrepareExaminationTime() {
        return prepareExaminationTime;
    }

    /**
     * 设置备考：考试时间
     *
     * @param prepareExaminationTime 备考：考试时间
     */
    public void setPrepareExaminationTime(String prepareExaminationTime) {
        this.prepareExaminationTime = prepareExaminationTime;
    }

    /**
     * 获取备考：出分时间
     *
     * @return prepare_score_time - 备考：出分时间
     */
    public Date getPrepareScoreTime() {
        return prepareScoreTime;
    }

    /**
     * 设置备考：出分时间
     *
     * @param prepareScoreTime 备考：出分时间
     */
    public void setPrepareScoreTime(Date prepareScoreTime) {
        this.prepareScoreTime = prepareScoreTime;
    }

    /**
     * 获取上次做题
     *
     * @return latest_exercise - 上次做题
     */
    public Integer getLatestExercise() {
        return latestExercise;
    }

    /**
     * 设置上次做题
     *
     * @param latestExercise 上次做题
     */
    public void setLatestExercise(Integer latestExercise) {
        this.latestExercise = latestExercise;
    }

    /**
     * 获取上一次错题组卷
     *
     * @return latest_error - 上一次错题组卷
     */
    public Integer getLatestError() {
        return latestError;
    }

    /**
     * 设置上一次错题组卷
     *
     * @param latestError 上一次错题组卷
     */
    public void setLatestError(Integer latestError) {
        this.latestError = latestError;
    }

    /**
     * 获取邀请用户
     *
     * @return origin_id - 邀请用户
     */
    public Integer getOriginId() {
        return originId;
    }

    /**
     * 设置邀请用户
     *
     * @param originId 邀请用户
     */
    public void setOriginId(Integer originId) {
        this.originId = originId;
    }

    /**
     * 获取个人邀请码
     *
     * @return invite_code - 个人邀请码
     */
    public String getInviteCode() {
        return inviteCode;
    }

    /**
     * 设置个人邀请码
     *
     * @param inviteCode 个人邀请码
     */
    public void setInviteCode(String inviteCode) {
        this.inviteCode = inviteCode;
    }

    /**
     * 获取消费金额
     *
     * @return total_money - 消费金额
     */
    public BigDecimal getTotalMoney() {
        return totalMoney;
    }

    /**
     * 设置消费金额
     *
     * @param totalMoney 消费金额
     */
    public void setTotalMoney(BigDecimal totalMoney) {
        this.totalMoney = totalMoney;
    }

    /**
     * 获取邀请人数
     *
     * @return invite_number - 邀请人数
     */
    public Integer getInviteNumber() {
        return inviteNumber;
    }

    /**
     * 设置邀请人数
     *
     * @param inviteNumber 邀请人数
     */
    public void setInviteNumber(Integer inviteNumber) {
        this.inviteNumber = inviteNumber;
    }

    /**
     * @return create_time
     */
    public Date getCreateTime() {
        return createTime;
    }

    /**
     * @param createTime
     */
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", nickname=").append(nickname);
        sb.append(", avatar=").append(avatar);
        sb.append(", password=").append(password);
        sb.append(", email=").append(email);
        sb.append(", area=").append(area);
        sb.append(", mobile=").append(mobile);
        sb.append(", wechatOpenidPc=").append(wechatOpenidPc);
        sb.append(", wechatOpenidWechat=").append(wechatOpenidWechat);
        sb.append(", wechatUnionid=").append(wechatUnionid);
        sb.append(", wechatAccessToken=").append(wechatAccessToken);
        sb.append(", wechatRefreshToken=").append(wechatRefreshToken);
        sb.append(", wechatExpireTime=").append(wechatExpireTime);
        sb.append(", realName=").append(realName);
        sb.append(", realAddress=").append(realAddress);
        sb.append(", realIdentity=").append(realIdentity);
        sb.append(", realPhoto=").append(realPhoto);
        sb.append(", realStatus=").append(realStatus);
        sb.append(", prepareStatus=").append(prepareStatus);
        sb.append(", prepareGoal=").append(prepareGoal);
        sb.append(", prepareExaminationTime=").append(prepareExaminationTime);
        sb.append(", prepareScoreTime=").append(prepareScoreTime);
        sb.append(", latestExercise=").append(latestExercise);
        sb.append(", latestError=").append(latestError);
        sb.append(", originId=").append(originId);
        sb.append(", inviteCode=").append(inviteCode);
        sb.append(", totalMoney=").append(totalMoney);
        sb.append(", inviteNumber=").append(inviteNumber);
        sb.append(", createTime=").append(createTime);
        sb.append("]");
        return sb.toString();
    }

    public static User.Builder builder() {
        return new User.Builder();
    }

    public static class Builder {
        private User obj;

        public Builder() {
            this.obj = new User();
        }

        /**
         * @param id
         */
        public Builder id(Integer id) {
            obj.setId(id);
            return this;
        }

        /**
         * 设置昵称
         *
         * @param nickname 昵称
         */
        public Builder nickname(String nickname) {
            obj.setNickname(nickname);
            return this;
        }

        /**
         * @param avatar
         */
        public Builder avatar(String avatar) {
            obj.setAvatar(avatar);
            return this;
        }

        /**
         * 设置密码
         *
         * @param password 密码
         */
        public Builder password(String password) {
            obj.setPassword(password);
            return this;
        }

        /**
         * 设置邮箱
         *
         * @param email 邮箱
         */
        public Builder email(String email) {
            obj.setEmail(email);
            return this;
        }

        /**
         * 设置手机-区号
         *
         * @param area 手机-区号
         */
        public Builder area(String area) {
            obj.setArea(area);
            return this;
        }

        /**
         * 设置手机
         *
         * @param mobile 手机
         */
        public Builder mobile(String mobile) {
            obj.setMobile(mobile);
            return this;
        }

        /**
         * 设置微信openid：pc端
         *
         * @param wechatOpenidPc 微信openid：pc端
         */
        public Builder wechatOpenidPc(String wechatOpenidPc) {
            obj.setWechatOpenidPc(wechatOpenidPc);
            return this;
        }

        /**
         * 设置微信openid: 公众号
         *
         * @param wechatOpenidWechat 微信openid: 公众号
         */
        public Builder wechatOpenidWechat(String wechatOpenidWechat) {
            obj.setWechatOpenidWechat(wechatOpenidWechat);
            return this;
        }

        /**
         * 设置微信关联id
         *
         * @param wechatUnionid 微信关联id
         */
        public Builder wechatUnionid(String wechatUnionid) {
            obj.setWechatUnionid(wechatUnionid);
            return this;
        }

        /**
         * 设置微信公众号accessToken
         *
         * @param wechatAccessToken 微信公众号accessToken
         */
        public Builder wechatAccessToken(String wechatAccessToken) {
            obj.setWechatAccessToken(wechatAccessToken);
            return this;
        }

        /**
         * 设置微信公众号refresh_token
         *
         * @param wechatRefreshToken 微信公众号refresh_token
         */
        public Builder wechatRefreshToken(String wechatRefreshToken) {
            obj.setWechatRefreshToken(wechatRefreshToken);
            return this;
        }

        /**
         * 设置微信公众号expireTime
         *
         * @param wechatExpireTime 微信公众号expireTime
         */
        public Builder wechatExpireTime(Date wechatExpireTime) {
            obj.setWechatExpireTime(wechatExpireTime);
            return this;
        }

        /**
         * 设置实名：姓名
         *
         * @param realName 实名：姓名
         */
        public Builder realName(String realName) {
            obj.setRealName(realName);
            return this;
        }

        /**
         * 设置实名：地址
         *
         * @param realAddress 实名：地址
         */
        public Builder realAddress(String realAddress) {
            obj.setRealAddress(realAddress);
            return this;
        }

        /**
         * 设置实名：身份ID
         *
         * @param realIdentity 实名：身份ID
         */
        public Builder realIdentity(String realIdentity) {
            obj.setRealIdentity(realIdentity);
            return this;
        }

        /**
         * 设置实名：身份证照片
         *
         * @param realPhoto 实名：身份证照片
         */
        public Builder realPhoto(String realPhoto) {
            obj.setRealPhoto(realPhoto);
            return this;
        }

        /**
         * 设置实名状态：0未实名，1已实名
         *
         * @param realStatus 实名状态：0未实名，1已实名
         */
        public Builder realStatus(Integer realStatus) {
            obj.setRealStatus(realStatus);
            return this;
        }

        /**
         * 设置备考：身份
         *
         * @param prepareStatus 备考：身份
         */
        public Builder prepareStatus(String prepareStatus) {
            obj.setPrepareStatus(prepareStatus);
            return this;
        }

        /**
         * 设置备考：目标分数
         *
         * @param prepareGoal 备考：目标分数
         */
        public Builder prepareGoal(Integer prepareGoal) {
            obj.setPrepareGoal(prepareGoal);
            return this;
        }

        /**
         * 设置备考：考试时间
         *
         * @param prepareExaminationTime 备考：考试时间
         */
        public Builder prepareExaminationTime(String prepareExaminationTime) {
            obj.setPrepareExaminationTime(prepareExaminationTime);
            return this;
        }

        /**
         * 设置备考：出分时间
         *
         * @param prepareScoreTime 备考：出分时间
         */
        public Builder prepareScoreTime(Date prepareScoreTime) {
            obj.setPrepareScoreTime(prepareScoreTime);
            return this;
        }

        /**
         * 设置上次做题
         *
         * @param latestExercise 上次做题
         */
        public Builder latestExercise(Integer latestExercise) {
            obj.setLatestExercise(latestExercise);
            return this;
        }

        /**
         * 设置上一次错题组卷
         *
         * @param latestError 上一次错题组卷
         */
        public Builder latestError(Integer latestError) {
            obj.setLatestError(latestError);
            return this;
        }

        /**
         * 设置邀请用户
         *
         * @param originId 邀请用户
         */
        public Builder originId(Integer originId) {
            obj.setOriginId(originId);
            return this;
        }

        /**
         * 设置个人邀请码
         *
         * @param inviteCode 个人邀请码
         */
        public Builder inviteCode(String inviteCode) {
            obj.setInviteCode(inviteCode);
            return this;
        }

        /**
         * 设置消费金额
         *
         * @param totalMoney 消费金额
         */
        public Builder totalMoney(BigDecimal totalMoney) {
            obj.setTotalMoney(totalMoney);
            return this;
        }

        /**
         * 设置邀请人数
         *
         * @param inviteNumber 邀请人数
         */
        public Builder inviteNumber(Integer inviteNumber) {
            obj.setInviteNumber(inviteNumber);
            return this;
        }

        /**
         * @param createTime
         */
        public Builder createTime(Date createTime) {
            obj.setCreateTime(createTime);
            return this;
        }

        public User build() {
            return this.obj;
        }
    }
}