package com.tax.file.model.token;

/**
 * @ProjectName: tax-sys
 * @Package: com.tax.file.model.token
 * @ClassName: tokenModel
 * @Author: ddx
 * @Description: ${description}
 * @Date: 2022-03-15 15:16
 * @Version: 1.0
 */
public class TokenInfoModel {

    private String token;
    private String tokenCode;
    private String tokenMessage;

    public TokenInfoModel() {
    }

    public TokenInfoModel(String token, String tokenCode) {
        this.token = token;
        this.tokenCode = tokenCode;
    }

    public TokenInfoModel(String token, String tokenCode, String tokenMessage) {
        this.token = token;
        this.tokenCode = tokenCode;
        this.tokenMessage = tokenMessage;
    }

    public boolean isStop(String userName) {
        boolean stopFlag = false;
        if(getTokenCode().equals("12008") || getTokenCode().equals("12011")) {
            stopFlag = true;
        }
        return stopFlag;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public String getTokenCode() {
        return tokenCode;
    }

    public void setTokenCode(String tokenCode) {
        this.tokenCode = tokenCode;
    }

    public String getTokenMessage() {
        return tokenMessage;
    }

    public void setTokenMessage(String tokenMessage) {
        this.tokenMessage = tokenMessage;
    }

    @Override
    public String toString() {
        return "TokenInfoModel{" +
                "token='" + token + '\'' +
                ", tokenCode='" + tokenCode + '\'' +
                ", tokenMessage='" + tokenMessage + '\'' +
                '}';
    }
}
